home *** CD-ROM | disk | FTP | other *** search
MacBinary | 1994-10-19 | 74.0 KB | [ONLN/HLX2] |
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: MacBinary
(archive/macBinary).
Confidence | Program | Detection | Match Type | Support
|
---|
10%
| dexvert
| MacBinary (archive/macBinary)
| fallback
| Supported |
100%
| file
| MacBinary II, inited, Mon Oct 10 07:32:02 1994, modified Wed Oct 19 10:11:09 1994, creator 'HLX2', type 'ONLN', 71863 bytes "PR09 Print Dialogues" , at 0x11937 3644 bytes resource
| default (weak)
| |
99%
| file
| data
| default
| |
66%
| TrID
| raw Group 3 FAX bitmap
| default (weak)
| |
33%
| TrID
| MacBinary 2
| default (weak)
| |
100%
| siegfried
| fmt/1762 MacBinary (II)
| default
| |
100%
| lsar
| MacBinary
| default
|
|
id metadata |
---|
key | value |
---|
macFileType | [ONLN] |
macFileCreator | [HLX2] |
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 14 50 52 30 39 20 50 | 72 69 6e 74 20 44 69 61 |..PR09 P|rint Dia|
|00000010| 6c 6f 67 75 65 73 00 00 | 00 00 00 00 00 00 00 00 |logues..|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 4f 4e 4c 4e 48 4c 58 | 32 01 00 00 00 00 00 00 |.ONLNHLX|2.......|
|00000050| 00 00 00 00 01 18 b7 00 | 00 0e 3c aa be d6 b2 aa |........|..<.....|
|00000060| ca d9 7d 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |..}.....|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 96 d4 00 00 |........|........|
|00000080| 50 52 20 39 20 2d 20 50 | 72 69 6e 74 20 44 69 61 |PR 9 - P|rint Dia|
|00000090| 6c 6f 67 73 3a 20 41 64 | 64 69 6e 67 20 49 74 65 |logs: Ad|ding Ite|
|000000a0| 6d 73 0d 50 72 69 6e 74 | 69 6e 67 09 0d 52 65 76 |ms.Print|ing..Rev|
|000000b0| 69 73 65 64 20 62 79 3a | 09 09 4d 61 72 63 68 20 |ised by:|..March |
|000000c0| 31 39 38 38 0d 57 72 69 | 74 74 65 6e 20 62 79 3a |1988.Wri|tten by:|
|000000d0| 09 47 69 6e 67 65 72 20 | 4a 65 72 6e 69 67 61 6e |.Ginger |Jernigan|
|000000e0| 09 4e 6f 76 65 6d 62 65 | 72 20 31 39 38 36 0d 09 |.Novembe|r 1986..|
|000000f0| 09 4c 65 77 20 52 6f 6c | 6c 69 6e 73 09 0d 54 68 |.Lew Rol|lins..Th|
|00000100| 69 73 20 74 65 63 68 6e | 69 63 61 6c 20 6e 6f 74 |is techn|ical not|
|00000110| 65 20 64 69 73 63 75 73 | 73 65 73 20 68 6f 77 20 |e discus|ses how |
|00000120| 74 6f 20 61 64 64 20 79 | 6f 75 72 20 6f 77 6e 20 |to add y|our own |
|00000130| 69 74 65 6d 73 20 74 6f | 20 74 68 65 20 50 72 69 |items to| the Pri|
|00000140| 6e 74 69 6e 67 20 4d 61 | 6e 61 67 65 72 d5 73 20 |nting Ma|nager.s |
|00000150| 64 69 61 6c 6f 67 73 2e | 0d 57 68 65 6e 20 74 68 |dialogs.|.When th|
|00000160| 65 20 50 72 69 6e 74 69 | 6e 67 20 4d 61 6e 61 67 |e Printi|ng Manag|
|00000170| 65 72 20 77 61 73 20 69 | 6e 69 74 69 61 6c 6c 79 |er was i|nitially|
|00000180| 20 64 65 73 69 67 6e 65 | 64 2c 20 67 72 65 61 74 | designe|d, great|
|00000190| 20 63 61 72 65 20 77 61 | 73 20 74 61 6b 65 6e 20 | care wa|s taken |
|000001a0| 74 6f 20 6d 61 6b 65 20 | 74 68 65 20 69 6e 74 65 |to make |the inte|
|000001b0| 72 66 61 63 65 20 74 6f | 20 74 68 65 20 70 72 69 |rface to| the pri|
|000001c0| 6e 74 65 72 20 64 72 69 | 76 65 72 73 20 61 73 20 |nter dri|vers as |
|000001d0| 67 65 6e 65 72 69 63 20 | 61 73 20 70 6f 73 73 69 |generic |as possi|
|000001e0| 62 6c 65 20 69 6e 20 6f | 72 64 65 72 20 74 6f 20 |ble in o|rder to |
|000001f0| 61 6c 6c 6f 77 20 61 70 | 70 6c 69 63 61 74 69 6f |allow ap|plicatio|
|00000200| 6e 73 20 74 6f 20 70 72 | 69 6e 74 20 77 69 74 68 |ns to pr|int with|
|00000210| 6f 75 74 20 62 65 69 6e | 67 20 64 65 76 69 63 65 |out bein|g device|
|00000220| 2d 73 70 65 63 69 66 69 | 63 2e 20 54 68 65 72 65 |-specifi|c. There|
|00000230| 20 61 72 65 20 74 69 6d | 65 73 2c 20 68 6f 77 65 | are tim|es, howe|
|00000240| 76 65 72 2c 20 77 68 65 | 6e 20 74 68 69 73 20 74 |ver, whe|n this t|
|00000250| 79 70 65 20 6f 66 20 6e | 6f 6e 2d 73 70 65 63 69 |ype of n|on-speci|
|00000260| 66 69 63 20 69 6e 74 65 | 72 66 61 63 65 20 69 6e |fic inte|rface in|
|00000270| 74 65 72 66 65 72 65 73 | 20 77 69 74 68 20 74 68 |terferes| with th|
|00000280| 65 20 66 6c 65 78 69 62 | 69 6c 69 74 79 20 6f 66 |e flexib|ility of|
|00000290| 20 61 6e 20 61 70 70 6c | 69 63 61 74 69 6f 6e 2e | an appl|ication.|
|000002a0| 20 41 6e 20 61 70 70 6c | 69 63 61 74 69 6f 6e 20 | An appl|ication |
|000002b0| 6d 61 79 20 72 65 71 75 | 69 72 65 20 61 64 64 69 |may requ|ire addi|
|000002c0| 74 69 6f 6e 61 6c 20 69 | 6e 66 6f 72 6d 61 74 69 |tional i|nformati|
|000002d0| 6f 6e 20 62 65 66 6f 72 | 65 20 70 72 69 6e 74 69 |on befor|e printi|
|000002e0| 6e 67 20 77 68 69 63 68 | 20 69 73 20 6e 6f 74 20 |ng which| is not |
|000002f0| 70 61 72 74 20 6f 66 20 | 74 68 65 20 67 65 6e 65 |part of |the gene|
|00000300| 72 61 6c 20 50 72 69 6e | 74 69 6e 67 20 4d 61 6e |ral Prin|ting Man|
|00000310| 61 67 65 72 20 69 6e 74 | 65 72 66 61 63 65 2e 20 |ager int|erface. |
|00000320| 54 68 69 73 20 74 65 63 | 68 6e 69 63 61 6c 20 6e |This tec|hnical n|
|00000330| 6f 74 65 20 64 65 73 63 | 72 69 62 65 73 20 61 20 |ote desc|ribes a |
|00000340| 6d 65 74 68 6f 64 20 74 | 68 61 74 20 61 6e 20 61 |method t|hat an a|
|00000350| 70 70 6c 69 63 61 74 69 | 6f 6e 20 63 61 6e 20 75 |pplicati|on can u|
|00000360| 73 65 20 74 6f 20 61 64 | 64 20 69 74 73 20 6f 77 |se to ad|d its ow|
|00000370| 6e 20 69 74 65 6d 73 20 | 74 6f 20 74 68 65 20 65 |n items |to the e|
|00000380| 78 69 73 74 69 6e 67 20 | 73 74 79 6c 65 20 61 6e |xisting |style an|
|00000390| 64 20 6a 6f 62 20 64 69 | 61 6c 6f 67 73 2e 0d 42 |d job di|alogs..B|
|000003a0| 65 66 6f 72 65 20 63 6f | 6e 74 69 6e 75 69 6e 67 |efore co|ntinuing|
|000003b0| 2c 20 79 6f 75 20 6e 65 | 65 64 20 74 6f 20 62 65 |, you ne|ed to be|
|000003c0| 20 61 77 61 72 65 20 6f | 66 20 73 6f 6d 65 20 67 | aware o|f some g|
|000003d0| 75 69 64 65 6c 69 6e 65 | 73 20 74 68 61 74 20 77 |uideline|s that w|
|000003e0| 69 6c 6c 20 69 6e 63 72 | 65 61 73 65 20 79 6f 75 |ill incr|ease you|
|000003f0| 72 20 63 68 61 6e 63 65 | 73 20 6f 66 20 62 65 69 |r chance|s of bei|
|00000400| 6e 67 20 63 6f 6d 70 61 | 74 69 62 6c 65 20 77 69 |ng compa|tible wi|
|00000410| 74 68 20 74 68 65 20 70 | 72 69 6e 74 69 6e 67 20 |th the p|rinting |
|00000420| 61 72 63 68 69 74 65 63 | 74 75 72 65 20 69 6e 20 |architec|ture in |
|00000430| 74 68 65 20 66 75 74 75 | 72 65 3a 0d a5 09 4f 6e |the futu|re:...On|
|00000440| 6c 79 20 61 64 64 20 69 | 74 65 6d 73 20 74 6f 20 |ly add i|tems to |
|00000450| 74 68 65 20 64 69 61 6c | 6f 67 73 20 61 73 20 64 |the dial|ogs as d|
|00000460| 65 73 63 72 69 62 65 64 | 20 69 6e 20 74 68 69 73 |escribed| in this|
|00000470| 20 74 65 63 68 6e 69 63 | 61 6c 20 6e 6f 74 65 2e | technic|al note.|
|00000480| 20 41 6e 79 20 6f 74 68 | 65 72 20 6d 65 74 68 6f | Any oth|er metho|
|00000490| 64 73 20 77 69 6c 6c 20 | 64 65 63 72 65 61 73 65 |ds will |decrease|
|000004a0| 20 79 6f 75 72 20 63 68 | 61 6e 63 65 73 20 6f 66 | your ch|ances of|
|000004b0| 20 73 75 72 76 69 76 61 | 6c 20 69 6e 20 74 68 65 | surviva|l in the|
|000004c0| 20 66 75 74 75 72 65 2e | 0d a5 09 44 6f 20 6e 6f | future.|...Do no|
|000004d0| 74 20 63 68 61 6e 67 65 | 20 74 68 65 20 70 6f 73 |t change| the pos|
|000004e0| 69 74 69 6f 6e 20 6f 66 | 20 61 6e 79 20 69 74 65 |ition of| any ite|
|000004f0| 6d 20 69 6e 20 74 68 65 | 20 63 75 72 72 65 6e 74 |m in the| current|
|00000500| 20 64 69 61 6c 6f 67 73 | 2e 20 54 68 69 73 20 6d | dialogs|. This m|
|00000510| 65 61 6e 73 20 64 6f 6e | d5 74 20 64 65 6c 65 74 |eans don|.t delet|
|00000520| 65 20 69 74 65 6d 73 20 | 66 72 6f 6d 20 74 68 65 |e items |from the|
|00000530| 20 65 78 69 73 74 69 6e | 67 20 69 74 65 6d 20 6c | existin|g item l|
|00000540| 69 73 74 20 6f 72 20 61 | 64 64 20 69 74 65 6d 73 |ist or a|dd items|
|00000550| 20 69 6e 20 74 68 65 20 | 6d 69 64 64 6c 65 2e 20 | in the |middle. |
|00000560| 41 64 64 20 69 74 65 6d | 73 20 6f 6e 6c 79 20 61 |Add item|s only a|
|00000570| 74 20 74 68 65 20 65 6e | 64 20 6f 66 20 74 68 65 |t the en|d of the|
|00000580| 20 6c 69 73 74 2e 0d a5 | 09 44 6f 6e d5 74 20 63 | list...|.Don.t c|
|00000590| 6f 75 6e 74 20 6f 6e 20 | 61 6e 20 69 74 65 6d 20 |ount on |an item |
|000005a0| 72 65 74 61 69 6e 69 6e | 67 20 69 74 73 20 63 75 |retainin|g its cu|
|000005b0| 72 72 65 6e 74 20 70 6f | 73 69 74 69 6f 6e 20 69 |rrent po|sition i|
|000005c0| 6e 20 74 68 65 20 6c 69 | 73 74 2e 20 49 66 20 79 |n the li|st. If y|
|000005d0| 6f 75 20 64 65 70 65 6e | 64 20 6f 6e 20 74 68 65 |ou depen|d on the|
|000005e0| 20 44 72 61 66 74 20 62 | 75 74 74 6f 6e 20 62 65 | Draft b|utton be|
|000005f0| 69 6e 67 20 61 20 70 61 | 72 74 69 63 75 6c 61 72 |ing a pa|rticular|
|00000600| 20 6e 75 6d 62 65 72 20 | 69 6e 20 74 68 65 20 49 | number |in the I|
|00000610| 6d 61 67 65 57 72 69 74 | 65 72 d5 73 20 73 74 79 |mageWrit|er.s sty|
|00000620| 6c 65 20 64 69 61 6c 6f | 67 20 69 74 65 6d 20 6c |le dialo|g item l|
|00000630| 69 73 74 2c 20 61 6e 64 | 20 77 65 20 63 68 61 6e |ist, and| we chan|
|00000640| 67 65 20 74 68 65 20 44 | 72 61 66 74 20 62 75 74 |ge the D|raft but|
|00000650| 74 6f 6e d5 73 20 69 74 | 65 6d 20 6e 75 6d 62 65 |ton.s it|em numbe|
|00000660| 72 20 66 6f 72 20 73 6f | 6d 65 20 72 65 61 73 6f |r for so|me reaso|
|00000670| 6e 2c 20 79 6f 75 72 20 | 70 72 6f 67 72 61 6d 20 |n, your |program |
|00000680| 6d 61 79 20 6e 6f 20 6c | 6f 6e 67 65 72 20 66 75 |may no l|onger fu|
|00000690| 6e 63 74 69 6f 6e 20 63 | 6f 72 72 65 63 74 6c 79 |nction c|orrectly|
|000006a0| 2e 0d a5 09 44 6f 6e d5 | 74 20 75 73 65 20 6d 6f |....Don.|t use mo|
|000006b0| 72 65 20 74 68 61 6e 20 | 68 61 6c 66 20 74 68 65 |re than |half the|
|000006c0| 20 73 63 72 65 65 6e 20 | 68 65 69 67 68 74 20 66 | screen |height f|
|000006d0| 6f 72 20 79 6f 75 72 20 | 69 74 65 6d 73 2e 20 41 |or your |items. A|
|000006e0| 70 70 6c 65 20 72 65 73 | 65 72 76 65 73 20 74 68 |pple res|erves th|
|000006f0| 65 20 72 69 67 68 74 20 | 74 6f 20 65 78 70 61 6e |e right |to expan|
|00000700| 64 20 74 68 65 20 69 74 | 65 6d 73 20 69 6e 20 74 |d the it|ems in t|
|00000710| 68 65 20 73 74 61 6e 64 | 61 72 64 20 70 72 69 6e |he stand|ard prin|
|00000720| 74 20 64 69 61 6c 6f 67 | 73 20 74 6f 20 66 69 6c |t dialog|s to fil|
|00000730| 6c 20 74 68 65 20 74 6f | 70 20 68 61 6c 66 20 6f |l the to|p half o|
|00000740| 66 20 74 68 65 20 73 63 | 72 65 65 6e 2e 0d a5 09 |f the sc|reen....|
|00000750| 49 66 20 79 6f 75 20 61 | 72 65 20 61 64 64 69 6e |If you a|re addin|
|00000760| 67 20 6c 6f 74 73 20 6f | 66 20 69 74 65 6d 73 20 |g lots o|f items |
|00000770| 74 6f 20 74 68 65 20 64 | 69 61 6c 6f 67 73 20 28 |to the d|ialogs (|
|00000780| 77 68 69 63 68 20 6d 61 | 79 20 63 6f 6e 66 75 73 |which ma|y confus|
|00000790| 65 20 75 73 65 72 73 29 | 2c 20 79 6f 75 20 73 68 |e users)|, you sh|
|000007a0| 6f 75 6c 64 20 63 6f 6e | 73 69 64 65 72 20 68 61 |ould con|sider ha|
|000007b0| 76 69 6e 67 20 79 6f 75 | 72 20 6f 77 6e 20 73 65 |ving you|r own se|
|000007c0| 70 61 72 61 74 65 20 64 | 69 61 6c 6f 67 20 69 6e |parate d|ialog in|
|000007d0| 20 61 64 64 69 74 69 6f | 6e 20 74 6f 20 74 68 65 | additio|n to the|
|000007e0| 20 65 78 69 73 74 69 6e | 67 20 50 72 69 6e 74 69 | existin|g Printi|
|000007f0| 6e 67 20 4d 61 6e 61 67 | 65 72 20 64 69 61 6c 6f |ng Manag|er dialo|
|00000800| 67 73 2e 0d 54 68 65 20 | 48 65 61 72 74 0d 42 65 |gs..The |Heart.Be|
|00000810| 66 6f 72 65 20 77 65 20 | 74 61 6c 6b 20 61 62 6f |fore we |talk abo|
|00000820| 75 74 20 68 6f 77 20 74 | 68 65 20 64 69 61 6c 6f |ut how t|he dialo|
|00000830| 67 73 20 77 6f 72 6b 2c | 20 79 6f 75 20 6e 65 65 |gs work,| you nee|
|00000840| 64 20 74 6f 20 6b 6e 6f | 77 20 74 68 69 73 3a 20 |d to kno|w this: |
|00000850| 61 74 20 74 68 65 20 68 | 65 61 72 74 20 6f 66 20 |at the h|eart of |
|00000860| 74 68 65 20 70 72 69 6e | 74 65 72 20 64 69 61 6c |the prin|ter dial|
|00000870| 6f 67 73 20 69 73 20 61 | 20 6c 69 74 74 6c 65 2d |ogs is a| little-|
|00000880| 6b 6e 6f 77 6e 20 64 61 | 74 61 20 73 74 72 75 63 |known da|ta struc|
|00000890| 74 75 72 65 20 70 61 72 | 74 69 61 6c 6c 79 20 64 |ture par|tially d|
|000008a0| 6f 63 75 6d 65 6e 74 65 | 64 20 69 6e 20 74 68 65 |ocumente|d in the|
|000008b0| 20 4d 61 63 50 72 69 6e | 74 20 69 6e 74 65 72 66 | MacPrin|t interf|
|000008c0| 61 63 65 20 66 69 6c 65 | 2e 20 49 74 d5 73 20 61 |ace file|. It.s a|
|000008d0| 20 72 65 63 6f 72 64 20 | 63 61 6c 6c 65 64 20 54 | record |called T|
|000008e0| 50 72 44 6c 67 20 61 6e | 64 20 69 74 20 6c 6f 6f |PrDlg an|d it loo|
|000008f0| 6b 73 20 6c 69 6b 65 20 | 74 68 69 73 3a 0d 09 54 |ks like |this:..T|
|00000900| 50 72 44 6c 67 20 3d 20 | 52 45 43 4f 52 44 20 20 |PrDlg = |RECORD |
|00000910| 20 7b 50 72 69 6e 74 20 | 44 69 61 6c 6f 67 3a 20 | {Print |Dialog: |
|00000920| 54 68 65 20 44 69 61 6c | 6f 67 20 53 74 72 65 61 |The Dial|og Strea|
|00000930| 6d 20 6f 62 6a 65 63 74 | 2e 7d 0d 09 20 20 20 64 |m object|.}.. d|
|00000940| 6c 67 20 20 20 20 20 20 | 20 3a 20 44 69 61 6c 6f |lg | : Dialo|
|00000950| 67 52 65 63 6f 72 64 3b | 20 20 20 7b 64 69 61 6c |gRecord;| {dial|
|00000960| 6f 67 20 77 69 6e 64 6f | 77 7d 0d 09 20 20 20 70 |og windo|w}.. p|
|00000970| 46 6c 74 72 50 72 6f 63 | 20 3a 20 50 72 6f 63 50 |FltrProc| : ProcP|
|00000980| 74 72 3b 20 20 20 20 20 | 20 20 20 7b 66 69 6c 74 |tr; | {filt|
|00000990| 65 72 20 70 72 6f 63 2e | 7d 0d 09 20 20 20 70 49 |er proc.|}.. pI|
|000009a0| 74 65 6d 50 72 6f 63 20 | 3a 20 50 72 6f 63 50 74 |temProc |: ProcPt|
|000009b0| 72 3b 20 20 20 20 20 20 | 20 20 7b 69 74 65 6d 20 |r; | {item |
|000009c0| 65 76 61 6c 75 61 74 69 | 6e 67 20 70 72 6f 63 2e |evaluati|ng proc.|
|000009d0| 7d 0d 09 20 20 20 68 50 | 72 69 6e 74 55 73 72 20 |}.. hP|rintUsr |
|000009e0| 3a 20 54 48 50 72 69 6e | 74 3b 20 20 20 20 20 20 |: THPrin|t; |
|000009f0| 20 20 7b 75 73 65 72 d5 | 73 20 70 72 69 6e 74 20 | {user.|s print |
|00000a00| 72 65 63 6f 72 64 2e 7d | 0d 09 20 20 20 66 44 6f |record.}|.. fDo|
|00000a10| 49 74 20 20 20 20 20 3a | 20 42 4f 4f 4c 45 41 4e |It :| BOOLEAN|
|00000a20| 3b 0d 09 20 20 20 66 44 | 6f 6e 65 20 20 20 20 20 |;.. fD|one |
|00000a30| 3a 20 42 4f 4f 4c 45 41 | 4e 3b 0d 09 20 20 20 6c |: BOOLEA|N;.. l|
|00000a40| 55 73 65 72 31 20 20 20 | 20 3a 20 4c 4f 4e 47 49 |User1 | : LONGI|
|00000a50| 4e 54 3b 20 20 20 20 20 | 20 20 20 7b 66 6f 75 72 |NT; | {four|
|00000a60| 20 6c 6f 6e 67 73 20 72 | 65 73 65 72 76 65 64 20 | longs r|eserved |
|00000a70| 62 79 20 41 70 70 6c 65 | 7d 0d 09 20 20 20 6c 55 |by Apple|}.. lU|
|00000a80| 73 65 72 32 20 20 20 20 | 3a 20 4c 4f 4e 47 49 4e |ser2 |: LONGIN|
|00000a90| 54 3b 0d 09 20 20 20 6c | 55 73 65 72 33 20 20 20 |T;.. l|User3 |
|00000aa0| 20 3a 20 4c 4f 4e 47 49 | 4e 54 3b 0d 09 20 20 20 | : LONGI|NT;.. |
|00000ab0| 6c 55 73 65 72 34 20 20 | 20 20 3a 20 4c 4f 4e 47 |lUser4 | : LONG|
|00000ac0| 49 4e 54 3b 0d 09 20 20 | 20 69 4e 75 6d 46 73 74 |INT;.. | iNumFst|
|00000ad0| 20 20 20 3a 20 49 4e 54 | 45 47 45 52 3b 20 20 20 | : INT|EGER; |
|00000ae0| 20 20 20 20 20 7b 6e 75 | 6d 65 72 69 63 20 65 64 | {nu|meric ed|
|00000af0| 69 74 20 69 74 65 6d 73 | 20 66 6f 72 20 73 74 64 |it items| for std|
|00000b00| 20 66 69 6c 74 65 72 7d | 0d 09 20 20 20 69 4e 75 | filter}|.. iNu|
|00000b10| 6d 4c 73 74 20 20 20 3a | 20 49 4e 54 45 47 45 52 |mLst :| INTEGER|
|00000b20| 3b 20 20 20 20 20 20 0d | 09 7b 2e 2e 2e 20 70 6c |; .|.{... pl|
|00000b30| 75 73 20 6d 6f 72 65 20 | 73 74 75 66 66 20 6e 65 |us more |stuff ne|
|00000b40| 65 64 65 64 20 62 79 20 | 74 68 65 20 70 61 72 74 |eded by |the part|
|00000b50| 69 63 75 6c 61 72 20 70 | 72 69 6e 74 69 6e 67 20 |icular p|rinting |
|00000b60| 64 69 61 6c 6f 67 2e 7d | 0d 09 45 4e 44 3b 0d 09 |dialog.}|..END;..|
|00000b70| 54 50 50 72 44 6c 67 20 | 3d 20 5e 54 50 72 44 6c |TPPrDlg |= ^TPrDl|
|00000b80| 67 3b 20 20 20 20 20 20 | 20 20 20 20 20 20 20 7b |g; | {|
|00000b90| 3d 3d 20 61 20 64 69 61 | 6c 6f 67 20 70 74 72 7d |== a dia|log ptr}|
|00000ba0| 0d 41 6c 6c 20 6f 66 20 | 74 68 65 20 69 6e 66 6f |.All of |the info|
|00000bb0| 72 6d 61 74 69 6f 6e 20 | 70 65 72 74 61 69 6e 69 |rmation |pertaini|
|00000bc0| 6e 67 20 74 6f 20 61 20 | 70 72 69 6e 74 20 64 69 |ng to a |print di|
|00000bd0| 61 6c 6f 67 20 69 73 20 | 6b 65 70 74 20 69 6e 20 |alog is |kept in |
|00000be0| 74 68 65 20 54 50 72 44 | 6c 67 20 72 65 63 6f 72 |the TPrD|lg recor|
|00000bf0| 64 2e 20 54 68 69 73 20 | 72 65 63 6f 72 64 20 77 |d. This |record w|
|00000c00| 69 6c 6c 20 62 65 20 72 | 65 66 65 72 72 65 64 20 |ill be r|eferred |
|00000c10| 74 6f 20 66 72 65 71 75 | 65 6e 74 6c 79 20 69 6e |to frequ|ently in|
|00000c20| 20 74 68 65 20 64 69 73 | 63 75 73 73 69 6f 6e 20 | the dis|cussion |
|00000c30| 62 65 6c 6f 77 2e 0d 48 | 6f 77 20 74 68 65 20 44 |below..H|ow the D|
|00000c40| 69 61 6c 6f 67 73 20 57 | 6f 72 6b 0d 57 68 65 6e |ialogs W|ork.When|
|00000c50| 20 79 6f 75 72 20 61 70 | 70 6c 69 63 61 74 69 6f | your ap|plicatio|
|00000c60| 6e 20 63 61 6c 6c 73 20 | 50 72 53 74 6c 44 69 61 |n calls |PrStlDia|
|00000c70| 6c 6f 67 20 61 6e 64 20 | 50 72 4a 6f 62 44 69 61 |log and |PrJobDia|
|00000c80| 6c 6f 67 2c 20 74 68 65 | 20 70 72 69 6e 74 65 72 |log, the| printer|
|00000c90| 20 64 72 69 76 65 72 20 | 61 63 74 75 61 6c 6c 79 | driver |actually|
|00000ca0| 20 63 61 6c 6c 73 20 61 | 20 72 6f 75 74 69 6e 65 | calls a| routine|
|00000cb0| 20 63 61 6c 6c 65 64 20 | 50 72 44 6c 67 4d 61 69 | called |PrDlgMai|
|00000cc0| 6e 2e 20 54 68 69 73 20 | 66 75 6e 63 74 69 6f 6e |n. This |function|
|00000cd0| 20 69 73 20 64 65 63 6c | 61 72 65 64 20 61 73 20 | is decl|ared as |
|00000ce0| 66 6f 6c 6c 6f 77 73 3a | 0d 09 46 55 4e 43 54 49 |follows:|..FUNCTI|
|00000cf0| 4f 4e 20 50 72 44 6c 67 | 4d 61 69 6e 20 28 68 70 |ON PrDlg|Main (hp|
|00000d00| 72 69 6e 74 3a 20 54 48 | 50 72 69 6e 74 3b 20 70 |rint: TH|Print; p|
|00000d10| 44 6c 67 49 6e 69 74 3a | 20 50 72 6f 63 50 74 72 |DlgInit:| ProcPtr|
|00000d20| 29 3a 20 42 4f 4f 4c 45 | 41 4e 3b 0d 50 72 44 6c |): BOOLE|AN;.PrDl|
|00000d30| 67 4d 61 69 6e 20 66 69 | 72 73 74 20 63 61 6c 6c |gMain fi|rst call|
|00000d40| 73 20 74 68 65 20 70 44 | 6c 67 49 6e 69 74 20 72 |s the pD|lgInit r|
|00000d50| 6f 75 74 69 6e 65 20 74 | 6f 20 73 65 74 20 75 70 |outine t|o set up|
|00000d60| 20 74 68 65 20 61 70 70 | 72 6f 70 72 69 61 74 65 | the app|ropriate|
|00000d70| 20 64 69 61 6c 6f 67 20 | 28 69 6e 20 44 6c 67 29 | dialog |(in Dlg)|
|00000d80| 2c 20 64 69 61 6c 6f 67 | 20 68 6f 6f 6b 20 28 70 |, dialog| hook (p|
|00000d90| 49 74 65 6d 50 72 6f 63 | 29 20 61 6e 64 20 64 69 |ItemProc|) and di|
|00000da0| 61 6c 6f 67 20 65 76 65 | 6e 74 20 66 69 6c 74 65 |alog eve|nt filte|
|00000db0| 72 20 28 70 46 69 6c 74 | 65 72 50 72 6f 63 29 20 |r (pFilt|erProc) |
|00000dc0| 69 6e 20 74 68 65 20 54 | 50 72 44 6c 67 20 72 65 |in the T|PrDlg re|
|00000dd0| 63 6f 72 64 20 28 73 68 | 6f 77 6e 20 61 62 6f 76 |cord (sh|own abov|
|00000de0| 65 29 2e 20 46 6f 72 20 | 74 68 65 20 6a 6f 62 20 |e). For |the job |
|00000df0| 64 69 61 6c 6f 67 2c 20 | 74 68 65 20 61 64 64 72 |dialog, |the addr|
|00000e00| 65 73 73 20 6f 66 20 50 | 72 4a 6f 62 49 6e 69 74 |ess of P|rJobInit|
|00000e10| 20 69 73 20 70 61 73 73 | 65 64 20 74 6f 20 50 72 | is pass|ed to Pr|
|00000e20| 44 6c 67 4d 61 69 6e 2e | 20 46 6f 72 20 74 68 65 |DlgMain.| For the|
|00000e30| 20 73 74 79 6c 65 20 64 | 69 61 6c 6f 67 2c 20 74 | style d|ialog, t|
|00000e40| 68 65 20 61 64 64 72 65 | 73 73 20 6f 66 20 50 72 |he addre|ss of Pr|
|00000e50| 53 74 6c 49 6e 69 74 20 | 69 73 20 70 61 73 73 65 |StlInit |is passe|
|00000e60| 64 2e 20 54 68 65 73 65 | 20 72 6f 75 74 69 6e 65 |d. These| routine|
|00000e70| 73 20 61 72 65 20 64 65 | 63 6c 61 72 65 64 20 61 |s are de|clared a|
|00000e80| 73 20 66 6f 6c 6c 6f 77 | 73 3a 0d 09 46 55 4e 43 |s follow|s:..FUNC|
|00000e90| 54 49 4f 4e 20 50 72 4a | 6f 62 49 6e 69 74 20 28 |TION PrJ|obInit (|
|00000ea0| 68 50 72 69 6e 74 3a 20 | 54 48 50 72 69 6e 74 29 |hPrint: |THPrint)|
|00000eb0| 3a 20 54 50 50 72 44 6c | 67 3b 0d 09 46 55 4e 43 |: TPPrDl|g;..FUNC|
|00000ec0| 54 49 4f 4e 20 50 72 53 | 74 6c 49 6e 69 74 20 28 |TION PrS|tlInit (|
|00000ed0| 68 50 72 69 6e 74 3a 20 | 54 48 50 72 69 6e 74 29 |hPrint: |THPrint)|
|00000ee0| 3a 20 54 50 50 72 44 6c | 67 3b 0d 41 66 74 65 72 |: TPPrDl|g;.After|
|00000ef0| 20 74 68 65 20 69 6e 69 | 74 69 61 6c 69 7a 61 74 | the ini|tializat|
|00000f00| 69 6f 6e 20 72 6f 75 74 | 69 6e 65 20 73 65 74 73 |ion rout|ine sets|
|00000f10| 20 75 70 20 74 68 65 20 | 54 50 72 44 6c 67 20 72 | up the |TPrDlg r|
|00000f20| 65 63 6f 72 64 2c 20 50 | 72 44 6c 67 4d 61 69 6e |ecord, P|rDlgMain|
|00000f30| 20 63 61 6c 6c 73 20 53 | 68 6f 77 57 69 6e 64 6f | calls S|howWindo|
|00000f40| 77 20 28 74 68 65 20 77 | 69 6e 64 6f 77 20 69 73 |w (the w|indow is|
|00000f50| 20 69 6e 69 74 69 61 6c | 6c 79 20 69 6e 76 69 73 | initial|ly invis|
|00000f60| 69 62 6c 65 29 2c 20 74 | 68 65 6e 20 69 74 20 63 |ible), t|hen it c|
|00000f70| 61 6c 6c 73 20 4d 6f 64 | 61 6c 44 69 61 6c 6f 67 |alls Mod|alDialog|
|00000f80| 2c 20 75 73 69 6e 67 20 | 74 68 65 20 64 69 61 6c |, using |the dial|
|00000f90| 6f 67 20 65 76 65 6e 74 | 20 66 69 6c 74 65 72 20 |og event| filter |
|00000fa0| 70 6f 69 6e 74 65 64 20 | 74 6f 20 62 79 20 74 68 |pointed |to by th|
|00000fb0| 65 20 70 46 6c 74 72 50 | 72 6f 63 20 66 69 65 6c |e pFltrP|roc fiel|
|00000fc0| 64 2e 20 57 68 65 6e 20 | 61 6e 20 69 74 65 6d 20 |d. When |an item |
|00000fd0| 69 73 20 68 69 74 2c 20 | 74 68 65 20 72 6f 75 74 |is hit, |the rout|
|00000fe0| 69 6e 65 20 70 6f 69 6e | 74 65 64 20 74 6f 20 62 |ine poin|ted to b|
|00000ff0| 79 20 74 68 65 20 70 49 | 74 65 6d 50 72 6f 63 20 |y the pI|temProc |
|00001000| 66 69 65 6c 64 20 69 73 | 20 63 61 6c 6c 65 64 20 |field is| called |
|00001010| 61 6e 64 20 74 68 65 20 | 69 74 65 6d 73 20 61 72 |and the |items ar|
|00001020| 65 20 68 61 6e 64 6c 65 | 64 20 61 70 70 72 6f 70 |e handle|d approp|
|00001030| 72 69 61 74 65 6c 79 2e | 20 57 68 65 6e 20 74 68 |riately.| When th|
|00001040| 65 20 4f 4b 20 62 75 74 | 74 6f 6e 20 69 73 20 68 |e OK but|ton is h|
|00001050| 69 74 20 28 74 68 69 73 | 20 69 6e 63 6c 75 64 65 |it (this| include|
|00001060| 73 20 70 72 65 73 73 69 | 6e 67 20 52 65 74 75 72 |s pressi|ng Retur|
|00001070| 6e 20 6f 72 20 45 6e 74 | 65 72 29 20 74 68 65 20 |n or Ent|er) the |
|00001080| 70 72 69 6e 74 20 72 65 | 63 6f 72 64 20 69 73 20 |print re|cord is |
|00001090| 76 61 6c 69 64 61 74 65 | 64 2e 20 54 68 65 20 70 |validate|d. The p|
|000010a0| 72 69 6e 74 20 72 65 63 | 6f 72 64 20 69 73 20 6e |rint rec|ord is n|
|000010b0| 6f 74 20 76 61 6c 69 64 | 61 74 65 64 20 69 66 20 |ot valid|ated if |
|000010c0| 74 68 65 20 43 61 6e 63 | 65 6c 20 62 75 74 74 6f |the Canc|el butto|
|000010d0| 6e 20 69 73 20 68 69 74 | 2e 0d 48 6f 77 20 74 6f |n is hit|..How to|
|000010e0| 20 41 64 64 20 59 6f 75 | 72 20 4f 77 6e 20 49 74 | Add You|r Own It|
|000010f0| 65 6d 73 0d 54 6f 20 6d | 6f 64 69 66 79 20 74 68 |ems.To m|odify th|
|00001100| 65 20 70 72 69 6e 74 20 | 64 69 61 6c 6f 67 73 2c |e print |dialogs,|
|00001110| 20 79 6f 75 20 6e 65 65 | 64 20 74 6f 20 63 68 61 | you nee|d to cha|
|00001120| 6e 67 65 20 74 68 65 20 | 54 50 72 44 6c 67 20 72 |nge the |TPrDlg r|
|00001130| 65 63 6f 72 64 20 62 65 | 66 6f 72 65 20 74 68 65 |ecord be|fore the|
|00001140| 20 64 69 61 6c 6f 67 20 | 69 73 20 64 72 61 77 6e | dialog |is drawn|
|00001150| 20 6f 6e 20 74 68 65 20 | 73 63 72 65 65 6e 2e 20 | on the |screen. |
|00001160| 59 6f 75 20 63 61 6e 20 | 61 64 64 20 79 6f 75 72 |You can |add your|
|00001170| 20 6f 77 6e 20 69 74 65 | 6d 73 20 74 6f 20 74 68 | own ite|ms to th|
|00001180| 65 20 69 74 65 6d 20 6c | 69 73 74 2c 20 72 65 70 |e item l|ist, rep|
|00001190| 6c 61 63 65 20 74 68 65 | 20 61 64 64 72 65 73 73 |lace the| address|
|000011a0| 65 73 20 6f 66 20 74 68 | 65 20 73 74 61 6e 64 61 |es of th|e standa|
|000011b0| 72 64 20 64 69 61 6c 6f | 67 20 68 6f 6f 6b 20 61 |rd dialo|g hook a|
|000011c0| 6e 64 20 65 76 65 6e 74 | 20 66 69 6c 74 65 72 20 |nd event| filter |
|000011d0| 77 69 74 68 20 74 68 65 | 20 61 64 64 72 65 73 73 |with the| address|
|000011e0| 65 73 20 6f 66 20 79 6f | 75 72 20 6f 77 6e 20 72 |es of yo|ur own r|
|000011f0| 6f 75 74 69 6e 65 73 20 | 61 6e 64 20 74 68 65 6e |outines |and then|
|00001200| 20 6c 65 74 20 74 68 65 | 20 64 69 61 6c 6f 67 20 | let the| dialog |
|00001210| 63 6f 64 65 20 63 6f 6e | 74 69 6e 75 65 20 6f 6e |code con|tinue on|
|00001220| 20 69 74 73 20 6d 65 72 | 72 79 20 77 61 79 2e 20 | its mer|ry way. |
|00001230| 0d 54 50 72 44 6c 67 20 | 72 65 63 6f 72 64 20 66 |.TPrDlg |record f|
|00001240| 6f 72 20 79 6f 75 20 61 | 6e 64 20 72 65 74 75 72 |or you a|nd retur|
|00001250| 6e 20 61 20 70 6f 69 6e | 74 65 72 20 74 6f 20 74 |n a poin|ter to t|
|00001260| 68 61 74 20 72 65 63 6f | 72 64 2e 20 54 68 65 6e |hat reco|rd. Then|
|00001270| 20 63 61 6c 6c 20 50 72 | 44 6c 67 4d 61 69 6e 20 | call Pr|DlgMain |
|00001280| 64 69 72 65 63 74 6c 79 | 2c 20 70 61 73 73 69 6e |directly|, passin|
|00001290| 67 20 69 6e 20 74 68 65 | 20 61 64 64 72 65 73 73 |g in the| address|
|000012a0| 20 6f 66 20 79 6f 75 72 | 20 6f 77 6e 20 69 6e 69 | of your| own ini|
|000012b0| 74 69 61 6c 69 7a 61 74 | 69 6f 6e 20 66 75 6e 63 |tializat|ion func|
|000012c0| 74 69 6f 6e 2e 20 54 68 | 65 20 65 78 61 6d 70 6c |tion. Th|e exampl|
|000012d0| 65 20 63 6f 64 65 d5 73 | 20 69 6e 69 74 69 61 6c |e code.s| initial|
|000012e0| 69 7a 61 74 69 6f 6e 20 | 66 75 6e 63 74 69 6f 6e |ization |function|
|000012f0| 20 61 64 64 73 20 69 74 | 65 6d 73 20 74 6f 20 74 | adds it|ems to t|
|00001300| 68 65 20 64 69 61 6c 6f | 67 20 69 74 65 6d 20 6c |he dialo|g item l|
|00001310| 69 73 74 2c 20 73 61 76 | 65 73 20 74 68 65 20 61 |ist, sav|es the a|
|00001320| 64 64 72 65 73 73 20 6f | 66 20 74 68 65 20 73 74 |ddress o|f the st|
|00001330| 61 6e 64 61 72 64 20 64 | 69 61 6c 6f 67 20 68 6f |andard d|ialog ho|
|00001340| 6f 6b 20 28 69 6e 20 6f | 75 72 20 67 6c 6f 62 61 |ok (in o|ur globa|
|00001350| 6c 20 76 61 72 69 61 62 | 6c 65 20 70 72 50 49 74 |l variab|le prPIt|
|00001360| 65 6d 50 72 6f 63 29 20 | 61 6e 64 20 70 75 74 73 |emProc) |and puts|
|00001370| 20 74 68 65 20 61 64 64 | 72 65 73 73 20 6f 66 20 | the add|ress of |
|00001380| 6f 75 72 20 64 69 61 6c | 6f 67 20 68 6f 6f 6b 20 |our dial|og hook |
|00001390| 69 6e 74 6f 20 74 68 65 | 20 70 49 74 65 6d 50 72 |into the| pItemPr|
|000013a0| 6f 63 20 66 69 65 6c 64 | 20 6f 66 20 74 68 65 20 |oc field| of the |
|000013b0| 54 50 72 44 6c 67 20 72 | 65 63 6f 72 64 2e 20 50 |TPrDlg r|ecord. P|
|000013c0| 6c 65 61 73 65 20 6e 6f | 74 65 20 74 68 61 74 20 |lease no|te that |
|000013d0| 79 6f 75 72 20 64 69 61 | 6c 6f 67 20 68 6f 6f 6b |your dia|log hook|
|000013e0| 20 6d 75 73 74 20 63 61 | 6c 6c 20 74 68 65 20 73 | must ca|ll the s|
|000013f0| 74 61 6e 64 61 72 64 20 | 64 69 61 6c 6f 67 20 68 |tandard |dialog h|
|00001400| 6f 6f 6b 20 74 6f 20 68 | 61 6e 64 6c 65 20 61 6c |ook to h|andle al|
|00001410| 6c 20 6f 66 20 74 68 65 | 20 73 74 61 6e 64 61 72 |l of the| standar|
|00001420| 64 20 64 69 61 6c 6f 67 | d5 73 20 69 74 65 6d 73 |d dialog|.s items|
|00001430| 2e 0d 4e 6f 74 65 3a 20 | 49 66 20 79 6f 75 20 77 |..Note: |If you w|
|00001440| 69 73 68 20 74 6f 20 68 | 61 76 65 20 61 6e 20 65 |ish to h|ave an e|
|00001450| 76 65 6e 74 20 66 69 6c | 74 65 72 2c 20 68 61 6e |vent fil|ter, han|
|00001460| 64 6c 65 20 69 74 20 74 | 68 65 20 73 61 6d 65 20 |dle it t|he same |
|00001470| 77 61 79 20 74 68 61 74 | 20 79 6f 75 20 64 6f 20 |way that| you do |
|00001480| 61 20 64 69 61 6c 6f 67 | 20 68 6f 6f 6b 2e 0d 4e |a dialog| hook..N|
|00001490| 6f 77 2c 20 68 65 72 65 | 20 69 73 20 61 6e 20 65 |ow, here| is an e|
|000014a0| 78 61 6d 70 6c 65 20 28 | 77 72 69 74 74 65 6e 20 |xample (|written |
|000014b0| 69 6e 20 4d 50 57 20 50 | 61 73 63 61 6c 29 20 74 |in MPW P|ascal) t|
|000014c0| 68 61 74 20 6d 6f 64 69 | 66 69 65 73 20 74 68 65 |hat modi|fies the|
|000014d0| 20 6a 6f 62 20 64 69 61 | 6c 6f 67 2e 20 54 68 65 | job dia|log. The|
|000014e0| 20 73 61 6d 65 20 63 6f | 64 65 20 77 6f 72 6b 73 | same co|de works|
|000014f0| 20 66 6f 72 20 74 68 65 | 20 73 74 79 6c 65 20 64 | for the| style d|
|00001500| 69 61 6c 6f 67 20 69 66 | 20 79 6f 75 20 67 6c 6f |ialog if| you glo|
|00001510| 62 61 6c 6c 79 20 72 65 | 70 6c 61 63 65 20 d4 4a |bally re|place .J|
|00001520| 6f 62 d5 20 77 69 74 68 | 20 d4 53 74 6c d5 2e 20 |ob. with| .Stl.. |
|00001530| 41 6c 73 6f 20 69 6e 63 | 6c 75 64 65 64 20 69 73 |Also inc|luded is|
|00001540| 20 61 20 66 75 6e 63 74 | 69 6f 6e 20 28 41 70 70 | a funct|ion (App|
|00001550| 65 6e 64 44 49 54 4c 29 | 20 70 72 6f 76 69 64 65 |endDITL)| provide|
|00001560| 64 20 62 79 20 4c 65 77 | 20 52 6f 6c 6c 69 6e 73 |d by Lew| Rollins|
|00001570| 20 28 6f 72 69 67 69 6e | 61 6c 6c 79 20 77 72 69 | (origin|ally wri|
|00001580| 74 74 65 6e 20 69 6e 20 | 43 2c 20 74 72 61 6e 73 |tten in |C, trans|
|00001590| 6c 61 74 65 64 20 66 6f | 72 20 74 68 69 73 20 74 |lated fo|r this t|
|000015a0| 65 63 68 6e 69 63 61 6c | 20 6e 6f 74 65 20 74 6f |echnical| note to|
|000015b0| 20 4d 50 57 20 50 61 73 | 63 61 6c 29 20 77 68 69 | MPW Pas|cal) whi|
|000015c0| 63 68 20 64 65 6d 6f 6e | 73 74 72 61 74 65 73 20 |ch demon|strates |
|000015d0| 61 20 6d 65 74 68 6f 64 | 20 6f 66 20 61 64 64 69 |a method| of addi|
|000015e0| 6e 67 20 69 74 65 6d 73 | 20 74 6f 20 74 68 65 20 |ng items| to the |
|000015f0| 69 74 65 6d 20 6c 69 73 | 74 2c 20 70 6c 61 63 69 |item lis|t, placi|
|00001600| 6e 67 20 74 68 65 6d 20 | 69 6e 20 61 6e 20 61 70 |ng them |in an ap|
|00001610| 70 72 6f 70 72 69 61 74 | 65 20 70 6c 61 63 65 2c |propriat|e place,|
|00001620| 20 61 6e 64 20 65 78 70 | 61 6e 64 69 6e 67 20 74 | and exp|anding t|
|00001630| 68 65 20 64 69 61 6c 6f | 67 20 77 69 6e 64 6f 77 |he dialo|g window|
|00001640| d5 73 20 72 65 63 74 61 | 6e 67 6c 65 2e 0d 54 68 |.s recta|ngle..Th|
|00001650| 65 20 4d 50 57 20 50 61 | 73 63 61 6c 20 45 78 61 |e MPW Pa|scal Exa|
|00001660| 6d 70 6c 65 20 50 72 6f | 67 72 61 6d 0d 50 52 4f |mple Pro|gram.PRO|
|00001670| 47 52 41 4d 20 4d 6f 64 | 69 66 79 44 69 61 6c 6f |GRAM Mod|ifyDialo|
|00001680| 67 73 3b 0d 09 55 53 45 | 53 0d 09 09 7b 24 4c 4f |gs;..USE|S...{$LO|
|00001690| 41 44 20 50 61 73 44 75 | 6d 70 2e 64 75 6d 70 7d |AD PasDu|mp.dump}|
|000016a0| 0d 09 09 4d 65 6d 54 79 | 70 65 73 2c 51 75 69 63 |...MemTy|pes,Quic|
|000016b0| 6b 44 72 61 77 2c 4f 53 | 49 6e 74 66 2c 54 6f 6f |kDraw,OS|Intf,Too|
|000016c0| 6c 49 6e 74 66 2c 50 61 | 63 6b 49 6e 74 66 2c 4d |lIntf,Pa|ckIntf,M|
|000016d0| 61 63 50 72 69 6e 74 3b | 0d 09 43 4f 4e 53 54 0d |acPrint;|..CONST.|
|000016e0| 09 09 4d 79 44 49 54 4c | 09 09 20 3d 20 32 35 36 |..MyDITL|.. = 256|
|000016f0| 3b 0d 09 09 4d 79 44 46 | 69 72 73 74 42 6f 78 20 |;...MyDF|irstBox |
|00001700| 20 3d 20 31 3b 20 09 09 | 20 7b 49 74 65 6d 20 6e | = 1; ..| {Item n|
|00001710| 75 6d 62 65 72 20 6f 66 | 20 66 69 72 73 74 20 62 |umber of| first b|
|00001720| 6f 78 20 69 6e 20 44 49 | 54 4c 7d 0d 09 09 4d 79 |ox in DI|TL}...My|
|00001730| 44 53 65 63 6f 6e 64 42 | 6f 78 20 3d 20 32 3b 0d |DSecondB|ox = 2;.|
|00001740| 09 56 41 52 0d 09 09 50 | 72 74 4a 6f 62 44 69 61 |.VAR...P|rtJobDia|
|00001750| 6c 6f 67 3a 20 54 50 50 | 72 44 6c 67 3b 09 7b 20 |log: TPP|rDlg;.{ |
|00001760| 70 6f 69 6e 74 65 72 20 | 74 6f 20 6a 6f 62 20 64 |pointer |to job d|
|00001770| 69 61 6c 6f 67 20 7d 0d | 09 09 68 50 72 69 6e 74 |ialog }.|..hPrint|
|00001780| 52 65 63 09 3a 20 54 48 | 50 72 69 6e 74 3b 09 7b |Rec.: TH|Print;.{|
|00001790| 20 48 61 6e 64 6c 65 20 | 74 6f 20 70 72 69 6e 74 | Handle |to print|
|000017a0| 20 72 65 63 6f 72 64 20 | 7d 0d 09 09 46 69 72 73 | record |}...Firs|
|000017b0| 74 42 6f 78 56 61 6c 75 | 65 2c 20 09 09 7b 20 76 |tBoxValu|e, ..{ v|
|000017c0| 61 6c 75 65 20 6f 66 20 | 66 69 72 73 74 20 61 64 |alue of |first ad|
|000017d0| 64 69 74 69 6f 6e 61 6c | 20 62 6f 78 20 7d 0d 09 |ditional| box }..|
|000017e0| 09 53 65 63 6f 6e 64 42 | 6f 78 56 61 6c 75 65 3a |.SecondB|oxValue:|
|000017f0| 20 49 6e 74 65 67 65 72 | 3b 20 09 7b 20 76 61 6c | Integer|; .{ val|
|00001800| 75 65 20 6f 66 20 73 65 | 63 6f 6e 64 20 61 64 64 |ue of se|cond add|
|00001810| 74 6c 2e 20 62 6f 78 20 | 7d 0d 09 09 70 72 46 69 |tl. box |}...prFi|
|00001820| 72 73 74 49 74 65 6d 2c | 09 09 09 7b 20 73 61 76 |rstItem,|...{ sav|
|00001830| 65 20 6f 75 72 20 66 69 | 72 73 74 20 69 74 65 6d |e our fi|rst item|
|00001840| 20 68 65 72 65 20 7d 0d | 09 09 70 72 50 49 74 65 | here }.|..prPIte|
|00001850| 6d 50 72 6f 63 20 3a 20 | 4c 6f 6e 67 49 6e 74 3b |mProc : |LongInt;|
|00001860| 09 7b 20 6e 65 65 64 20 | 74 6f 20 73 74 6f 72 65 |.{ need |to store|
|00001870| 20 6f 6c 64 20 69 74 65 | 6d 50 72 6f 63 20 68 65 | old ite|mProc he|
|00001880| 72 65 20 7d 0d 09 09 69 | 74 65 6d 54 79 70 65 20 |re }...i|temType |
|00001890| 09 3a 20 49 6e 74 65 67 | 65 72 3b 09 7b 20 6e 65 |.: Integ|er;.{ ne|
|000018a0| 65 64 20 66 6f 72 20 47 | 65 74 44 49 74 65 6d 2f |ed for G|etDItem/|
|000018b0| 53 65 74 44 49 74 65 6d | 20 63 61 6c 6c 73 20 7d |SetDItem| calls }|
|000018c0| 0d 09 09 69 74 65 6d 48 | 20 09 09 3a 20 48 61 6e |...itemH| ..: Han|
|000018d0| 64 6c 65 3b 0d 09 09 69 | 74 65 6d 42 6f 78 09 09 |dle;...i|temBox..|
|000018e0| 3a 20 52 65 63 74 3b 0d | 09 09 65 72 72 09 09 09 |: Rect;.|..err...|
|000018f0| 3a 20 4f 53 45 72 72 3b | 0d 7b 2d 2d 2d 2d 2d 2d |: OSErr;|.{------|
|00001900| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001910| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001920| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001930| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001940| 2d 2d 7d 0d 09 50 52 4f | 43 45 44 55 52 45 20 5f |--}..PRO|CEDURE _|
|00001950| 44 61 74 61 49 6e 69 74 | 3b 0d 09 09 45 58 54 45 |DataInit|;...EXTE|
|00001960| 52 4e 41 4c 3b 0d 7b 2d | 2d 2d 2d 2d 2d 2d 2d 2d |RNAL;.{-|--------|
|00001970| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001980| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001990| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000019a0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 7d |--------|-------}|
|000019b0| 0d 09 50 52 4f 43 45 44 | 55 52 45 20 43 61 6c 6c |..PROCED|URE Call|
|000019c0| 49 74 65 6d 48 61 6e 64 | 6c 65 72 28 74 68 65 44 |ItemHand|ler(theD|
|000019d0| 69 61 6c 6f 67 3a 20 44 | 69 61 6c 6f 67 50 74 72 |ialog: D|ialogPtr|
|000019e0| 3b 20 74 68 65 49 74 65 | 6d 3a 20 49 6e 74 65 67 |; theIte|m: Integ|
|000019f0| 65 72 3b 0d 09 09 09 09 | 09 74 68 65 50 72 6f 63 |er;.....|.theProc|
|00001a00| 3a 20 4c 6f 6e 67 49 6e | 74 29 3b 0d 09 09 49 4e |: LongIn|t);...IN|
|00001a10| 4c 49 4e 45 20 24 32 30 | 35 46 09 09 09 7b 20 4d |LINE $20|5F...{ M|
|00001a20| 4f 56 45 2e 4c 20 28 41 | 37 29 2b 2c 41 30 7d 0d |OVE.L (A|7)+,A0}.|
|00001a30| 09 09 2c 24 34 45 39 30 | 3b 09 09 09 7b 20 4a 53 |..,$4E90|;...{ JS|
|00001a40| 52 20 28 41 30 29 20 7d | 0d 7b 20 74 68 69 73 20 |R (A0) }|.{ this |
|00001a50| 63 6f 64 65 20 70 6f 70 | 73 20 6f 66 66 20 74 68 |code pop|s off th|
|00001a60| 65 50 72 6f 63 20 61 6e | 64 20 74 68 65 6e 20 64 |eProc an|d then d|
|00001a70| 6f 65 73 20 61 20 4a 53 | 52 20 74 6f 20 69 74 2c |oes a JS|R to it,|
|00001a80| 20 77 68 69 63 68 20 70 | 75 74 73 20 74 68 65 0d | which p|uts the.|
|00001a90| 20 72 65 61 6c 20 72 65 | 74 75 72 6e 20 61 64 64 | real re|turn add|
|00001aa0| 72 65 73 73 20 6f 6e 20 | 74 68 65 20 73 74 61 63 |ress on |the stac|
|00001ab0| 6b 2e 20 7d 0d 7b 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |k. }.{--|--------|
|00001ac0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001ad0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001ae0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00001af0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 7d 0d |--------|------}.|
|00001b00| 09 46 55 4e 43 54 49 4f | 4e 20 41 70 70 65 6e 64 |.FUNCTIO|N Append|
|00001b10| 44 49 54 4c 28 74 68 65 | 44 69 61 6c 6f 67 3a 20 |DITL(the|Dialog: |
|00001b20| 44 69 61 6c 6f 67 50 74 | 72 3b 20 74 68 65 44 49 |DialogPt|r; theDI|
|00001b30| 54 4c 49 44 3a 20 49 6e | 74 65 67 65 72 29 3a 20 |TLID: In|teger): |
|00001b40| 49 6e 74 65 67 65 72 3b | 0d 09 7b 20 76 65 72 73 |Integer;|..{ vers|
|00001b50| 69 6f 6e 20 30 2e 31 20 | 39 2f 31 31 2f 38 36 20 |ion 0.1 |9/11/86 |
|00001b60| 4c 65 77 20 52 6f 6c 6c | 69 6e 73 20 6f 66 20 48 |Lew Roll|ins of H|
|00001b70| 75 6d 61 6e 2d 53 79 73 | 74 65 6d 73 20 49 6e 74 |uman-Sys|tems Int|
|00001b80| 65 72 66 61 63 65 20 47 | 72 6f 75 70 7d 0d 09 7b |erface G|roup}..{|
|00001b90| 20 74 68 69 73 20 72 6f | 75 74 69 6e 65 20 73 74 | this ro|utine st|
|00001ba0| 69 6c 6c 20 6e 65 65 64 | 73 20 73 6f 6d 65 20 65 |ill need|s some e|
|00001bb0| 72 72 6f 72 20 63 68 65 | 63 6b 69 6e 67 20 7d 0d |rror che|cking }.|
|00001bc0| 7b 20 54 68 69 73 20 72 | 6f 75 74 69 6e 65 20 61 |{ This r|outine a|
|00001bd0| 70 70 65 6e 64 73 20 61 | 6c 6c 20 6f 66 20 74 68 |ppends a|ll of th|
|00001be0| 65 20 69 74 65 6d 73 20 | 6f 66 20 61 20 73 70 65 |e items |of a spe|
|00001bf0| 63 69 66 69 65 64 20 44 | 49 54 4c 0d 6f 6e 74 6f |cified D|ITL.onto|
|00001c00| 20 74 68 65 20 65 6e 64 | 20 6f 66 20 61 20 73 70 | the end| of a sp|
|00001c10| 65 63 69 66 69 65 64 20 | 44 4c 4f 47 20 d1 20 57 |ecified |DLOG . W|
|00001c20| 65 20 64 6f 6e d5 74 20 | 65 76 65 6e 20 6e 65 65 |e don.t |even nee|
|00001c30| 64 20 74 6f 20 6b 6e 6f | 77 20 74 68 65 20 66 6f |d to kno|w the fo|
|00001c40| 72 6d 61 74 0d 6f 66 20 | 74 68 65 20 44 4c 4f 47 |rmat.of |the DLOG|
|00001c50| 20 7d 0d 7b 20 74 68 69 | 73 20 77 69 6c 6c 20 62 | }.{ thi|s will b|
|00001c60| 65 20 64 6f 6e 65 20 69 | 6e 20 33 20 73 74 65 70 |e done i|n 3 step|
|00001c70| 73 3a 0d 20 31 2e 20 61 | 70 70 65 6e 64 20 74 68 |s:. 1. a|ppend th|
|00001c80| 65 20 69 74 65 6d 73 20 | 6f 66 20 74 68 65 20 73 |e items |of the s|
|00001c90| 70 65 63 69 66 69 65 64 | 20 44 49 54 4c 20 6f 6e |pecified| DITL on|
|00001ca0| 74 6f 20 74 68 65 20 65 | 78 69 73 74 69 6e 67 20 |to the e|xisting |
|00001cb0| 44 4c 4f 47 0d 20 32 2e | 20 65 78 70 61 6e 64 20 |DLOG. 2.| expand |
|00001cc0| 74 68 65 20 6f 72 69 67 | 69 6e 61 6c 20 64 69 61 |the orig|inal dia|
|00001cd0| 6c 6f 67 20 77 69 6e 64 | 6f 77 20 61 73 20 72 65 |log wind|ow as re|
|00001ce0| 71 75 69 72 65 64 0d 20 | 33 2e 20 72 65 74 75 72 |quired. |3. retur|
|00001cf0| 6e 20 74 68 65 20 61 64 | 6a 75 73 74 65 64 20 6e |n the ad|justed n|
|00001d00| 75 6d 62 65 72 20 6f 66 | 20 74 68 65 20 66 69 72 |umber of| the fir|
|00001d10| 73 74 20 6e 65 77 20 75 | 73 65 72 20 69 74 65 6d |st new u|ser item|
|00001d20| 0d 7d 0d 09 54 59 50 45 | 0d 09 09 44 49 54 4c 49 |.}..TYPE|...DITLI|
|00001d30| 74 65 6d 20 3d 20 52 45 | 43 4f 52 44 09 7b 20 46 |tem = RE|CORD.{ F|
|00001d40| 69 72 73 74 2c 20 61 20 | 73 69 6e 67 6c 65 20 69 |irst, a |single i|
|00001d50| 74 65 6d 20 7d 0d 09 09 | 09 7b 20 48 61 6e 64 6c |tem }...|.{ Handl|
|00001d60| 65 20 6f 72 20 70 72 6f | 63 65 64 75 72 65 20 70 |e or pro|cedure p|
|00001d70| 6f 69 6e 74 65 72 20 66 | 6f 72 20 74 68 69 73 20 |ointer f|or this |
|00001d80| 69 74 65 6d 20 7d 0d 09 | 09 09 09 69 74 6d 48 6e |item }..|...itmHn|
|00001d90| 64 6c 3a 20 48 61 6e 64 | 6c 65 3b 0d 09 09 09 7b |dl: Hand|le;....{|
|00001da0| 20 44 69 73 70 6c 61 79 | 20 72 65 63 74 61 6e 67 | Display| rectang|
|00001db0| 6c 65 20 66 6f 72 20 74 | 68 69 73 20 69 74 65 6d |le for t|his item|
|00001dc0| 20 7d 0d 09 09 09 09 69 | 74 6d 52 65 63 74 3a 20 | }.....i|tmRect: |
|00001dd0| 52 65 63 74 3b 20 0d 09 | 09 09 7b 20 49 74 65 6d |Rect; ..|..{ Item|
|00001de0| 20 74 79 70 65 20 66 6f | 72 20 74 68 69 73 20 69 | type fo|r this i|
|00001df0| 74 65 6d 20 d1 20 31 20 | 62 79 74 65 20 7d 0d 09 |tem . 1 |byte }..|
|00001e00| 09 09 09 69 74 6d 54 79 | 70 65 3a 20 53 69 67 6e |...itmTy|pe: Sign|
|00001e10| 65 64 42 79 74 65 3b 0d | 09 09 09 7b 20 4c 65 6e |edByte;.|...{ Len|
|00001e20| 67 74 68 20 62 79 74 65 | 20 6f 66 20 64 61 74 61 |gth byte| of data|
|00001e30| 20 7d 0d 09 09 09 09 69 | 74 6d 44 61 74 61 3a 20 | }.....i|tmData: |
|00001e40| 41 52 52 41 59 20 5b 30 | 2e 2e 30 5d 20 4f 46 20 |ARRAY [0|..0] OF |
|00001e50| 53 69 67 6e 65 64 42 79 | 74 65 3b 0d 09 09 45 4e |SignedBy|te;...EN|
|00001e60| 44 3b 09 7b 44 49 54 4c | 49 74 65 6d 7d 0d 09 09 |D;.{DITL|Item}...|
|00001e70| 70 44 49 54 4c 49 74 65 | 6d 09 20 3d 20 5e 44 49 |pDITLIte|m. = ^DI|
|00001e80| 54 4c 49 74 65 6d 3b 0d | 09 09 68 44 49 54 4c 49 |TLItem;.|..hDITLI|
|00001e90| 74 65 6d 09 20 3d 20 5e | 70 44 49 54 4c 49 74 65 |tem. = ^|pDITLIte|
|00001ea0| 6d 3b 0d 09 09 49 74 65 | 6d 4c 69 73 74 20 3d 20 |m;...Ite|mList = |
|00001eb0| 52 45 43 4f 52 44 09 7b | 20 54 68 65 6e 2c 20 74 |RECORD.{| Then, t|
|00001ec0| 68 65 20 6c 69 73 74 20 | 6f 66 20 69 74 65 6d 73 |he list |of items|
|00001ed0| 20 7d 0d 09 09 09 20 7b | 20 4e 75 6d 62 65 72 20 | }.... {| Number |
|00001ee0| 6f 66 20 69 74 65 6d 73 | 20 6d 69 6e 75 73 20 31 |of items| minus 1|
|00001ef0| 20 7d 0d 09 09 09 09 64 | 6c 67 4d 61 78 49 6e 64 | }.....d|lgMaxInd|
|00001f00| 65 78 3a 20 49 6e 74 65 | 67 65 72 3b 0d 09 09 09 |ex: Inte|ger;....|
|00001f10| 7b 20 41 72 72 61 79 20 | 6f 66 20 69 74 65 6d 73 |{ Array |of items|
|00001f20| 20 7d 0d 09 09 09 09 44 | 49 54 4c 49 74 65 6d 73 | }.....D|ITLItems|
|00001f30| 3a 20 41 52 52 41 59 20 | 5b 30 2e 2e 30 5d 20 4f |: ARRAY |[0..0] O|
|00001f40| 46 20 44 49 54 4c 49 74 | 65 6d 3b 09 09 09 45 4e |F DITLIt|em;...EN|
|00001f50| 44 3b 09 20 7b 49 74 65 | 6d 4c 69 73 74 7d 0d 09 |D;. {Ite|mList}..|
|00001f60| 09 70 49 74 65 6d 4c 69 | 73 74 09 20 3d 20 5e 49 |.pItemLi|st. = ^I|
|00001f70| 74 65 6d 4c 69 73 74 3b | 0d 09 09 68 49 74 65 6d |temList;|...hItem|
|00001f80| 4c 69 73 74 09 20 3d 20 | 5e 70 49 74 65 6d 4c 69 |List. = |^pItemLi|
|00001f90| 73 74 3b 0d 09 09 49 6e | 74 50 74 72 09 09 20 3d |st;...In|tPtr.. =|
|00001fa0| 20 5e 49 6e 74 65 67 65 | 72 3b 0d 09 56 41 52 0d | ^Intege|r;..VAR.|
|00001fb0| 09 09 6f 66 66 73 65 74 | 20 3a 20 50 6f 69 6e 74 |..offset| : Point|
|00001fc0| 3b 09 7b 20 55 73 65 64 | 20 74 6f 20 6f 66 66 73 |;.{ Used| to offs|
|00001fd0| 65 74 20 72 65 63 74 61 | 6e 67 6c 65 73 20 61 70 |et recta|ngles ap|
|00001fe0| 70 65 6e 64 65 64 20 69 | 74 65 6d 73 7d 0d 09 09 |pended i|tems}...|
|00001ff0| 6d 61 78 52 65 63 74 3a | 20 52 65 63 74 3b 09 7b |maxRect:| Rect;.{|
|00002000| 20 55 73 65 64 20 74 6f | 20 74 72 61 63 6b 20 69 | Used to| track i|
|00002010| 6e 63 72 65 61 73 65 73 | 20 69 6e 20 77 69 6e 64 |ncreases| in wind|
|00002020| 6f 77 20 73 69 7a 65 20 | 7d 0d 09 09 68 44 49 54 |ow size |}...hDIT|
|00002030| 4c 20 3a 20 68 49 74 65 | 6d 4c 69 73 74 3b 20 09 |L : hIte|mList; .|
|00002040| 7b 20 48 61 6e 64 6c 65 | 20 74 6f 20 44 49 54 4c |{ Handle| to DITL|
|00002050| 20 62 65 69 6e 67 20 61 | 70 70 65 6e 64 65 64 20 | being a|ppended |
|00002060| 7d 0d 09 09 70 49 74 65 | 6d 20 3a 20 70 44 49 54 |}...pIte|m : pDIT|
|00002070| 4c 49 74 65 6d 3b 09 7b | 20 50 6f 69 6e 74 65 72 |LItem;.{| Pointer|
|00002080| 20 74 6f 20 63 75 72 72 | 65 6e 74 20 69 74 65 6d | to curr|ent item|
|00002090| 20 62 65 69 6e 67 20 61 | 70 70 65 6e 64 65 64 20 | being a|ppended |
|000020a0| 7d 0d 09 09 68 49 74 65 | 6d 73 3a 20 68 49 74 65 |}...hIte|ms: hIte|
|000020b0| 6d 4c 69 73 74 3b 09 7b | 20 48 61 6e 64 6c 65 20 |mList;.{| Handle |
|000020c0| 74 6f 20 44 4c 4f 47 d5 | 73 20 69 74 65 6d 20 6c |to DLOG.|s item l|
|000020d0| 69 73 74 20 7d 0d 09 09 | 66 69 72 73 74 49 74 65 |ist }...|firstIte|
|000020e0| 6d 3a 20 49 6e 74 65 67 | 65 72 3b 09 7b 20 6f 66 |m: Integ|er;.{ of|
|000020f0| 66 73 65 74 20 74 6f 20 | 66 69 72 73 74 20 69 74 |fset to |first it|
|00002100| 65 6d 20 69 73 20 74 6f | 20 62 65 20 61 70 70 65 |em is to| be appe|
|00002110| 6e 64 65 64 20 7d 0d 09 | 09 6e 65 77 49 74 65 6d |nded }..|.newItem|
|00002120| 73 3a 20 49 6e 74 65 67 | 65 72 3b 09 7b 20 43 6f |s: Integ|er;.{ Co|
|00002130| 75 6e 74 20 6f 66 20 6e | 65 77 20 69 74 65 6d 73 |unt of n|ew items|
|00002140| 20 7d 0d 09 09 64 61 74 | 61 53 69 7a 65 20 3a 20 | }...dat|aSize : |
|00002150| 49 6e 74 65 67 65 72 3b | 09 7b 20 53 69 7a 65 20 |Integer;|.{ Size |
|00002160| 6f 66 20 64 61 74 61 20 | 66 6f 72 20 63 75 72 72 |of data |for curr|
|00002170| 65 6e 74 20 69 74 65 6d | 20 7d 0d 09 09 69 20 3a |ent item| }...i :|
|00002180| 20 49 6e 74 65 67 65 72 | 3b 20 09 09 7b 20 57 6f | Integer|; ..{ Wo|
|00002190| 72 6b 69 6e 67 20 69 6e | 64 65 78 20 7d 0d 09 09 |rking in|dex }...|
|000021a0| 55 53 42 3a 20 52 45 43 | 4f 52 44 09 09 7b 20 6e |USB: REC|ORD..{ n|
|000021b0| 65 65 64 65 64 20 62 65 | 63 61 75 73 65 20 69 74 |eeded be|cause it|
|000021c0| 6d 44 61 74 61 5b 30 5d | 20 69 73 20 75 6e 73 69 |mData[0]| is unsi|
|000021d0| 67 6e 65 64 7d 0d 09 09 | 09 43 41 53 45 20 49 6e |gned}...|.CASE In|
|000021e0| 74 65 67 65 72 20 4f 46 | 0d 09 09 09 09 31 3a 0d |teger OF|.....1:.|
|000021f0| 09 09 09 09 09 28 53 42 | 41 72 72 61 79 3a 20 41 |.....(SB|Array: A|
|00002200| 52 52 41 59 20 5b 30 2e | 2e 31 5d 20 4f 46 20 53 |RRAY [0.|.1] OF S|
|00002210| 69 67 6e 65 64 42 79 74 | 65 29 3b 0d 09 09 09 09 |ignedByt|e);.....|
|00002220| 32 3a 0d 09 09 09 09 09 | 28 49 6e 74 3a 20 49 6e |2:......|(Int: In|
|00002230| 74 65 67 65 72 29 3b 0d | 09 09 45 4e 44 3b 09 20 |teger);.|..END;. |
|00002240| 7b 55 53 42 7d 0d 09 42 | 45 47 49 4e 20 09 09 7b |{USB}..B|EGIN ..{|
|00002250| 41 70 70 65 6e 64 44 49 | 54 4c 7d 0d 7b 0d 55 73 |AppendDI|TL}.{.Us|
|00002260| 69 6e 67 20 74 68 65 20 | 6f 72 69 67 69 6e 61 6c |ing the |original|
|00002270| 20 44 4c 4f 47 0d 20 31 | 2e 20 52 65 6d 65 6d 62 | DLOG. 1|. Rememb|
|00002280| 65 72 20 74 68 65 20 6f | 72 69 67 69 6e 61 6c 20 |er the o|riginal |
|00002290| 77 69 6e 64 6f 77 20 53 | 69 7a 65 2e 0d 20 32 2e |window S|ize.. 2.|
|000022a0| 20 53 65 74 20 74 68 65 | 20 6f 66 66 73 65 74 20 | Set the| offset |
|000022b0| 50 6f 69 6e 74 20 74 6f | 20 62 65 20 74 68 65 20 |Point to| be the |
|000022c0| 62 6f 74 74 6f 6d 20 6f | 66 20 74 68 65 20 6f 72 |bottom o|f the or|
|000022d0| 69 67 69 6e 61 6c 20 77 | 69 6e 64 6f 77 2e 0d 20 |iginal w|indow.. |
|000022e0| 33 2e 20 53 75 62 74 72 | 61 63 74 20 35 20 70 69 |3. Subtr|act 5 pi|
|000022f0| 78 65 6c 73 20 66 72 6f | 6d 20 62 6f 74 74 6f 6d |xels fro|m bottom|
|00002300| 20 61 6e 64 20 72 69 67 | 68 74 2c 20 74 6f 20 62 | and rig|ht, to b|
|00002310| 65 20 61 64 64 65 64 0d | 20 20 20 20 20 20 62 61 |e added.| ba|
|00002320| 63 6b 20 6c 61 74 65 72 | 20 61 66 74 65 72 20 77 |ck later| after w|
|00002330| 65 20 68 61 76 65 20 70 | 6f 73 73 69 62 6c 79 20 |e have p|ossibly |
|00002340| 65 78 70 61 6e 64 65 64 | 20 77 69 6e 64 6f 77 2e |expanded| window.|
|00002350| 0d 20 34 2e 20 47 65 74 | 20 77 6f 72 6b 69 6e 67 |. 4. Get| working|
|00002360| 20 48 61 6e 64 6c 65 20 | 74 6f 20 6f 72 69 67 69 | Handle |to origi|
|00002370| 6e 61 6c 20 69 74 65 6d | 20 6c 69 73 74 2e 0d 20 |nal item| list.. |
|00002380| 35 2e 20 43 61 6c 63 75 | 6c 61 74 65 20 6f 75 72 |5. Calcu|late our|
|00002390| 20 66 69 72 73 74 20 69 | 74 65 6d 20 6e 75 6d 62 | first i|tem numb|
|000023a0| 65 72 20 74 6f 20 62 65 | 20 72 65 74 75 72 6e 65 |er to be| returne|
|000023b0| 64 20 74 6f 20 63 61 6c | 6c 65 72 2e 0d 20 36 2e |d to cal|ler.. 6.|
|000023c0| 20 47 65 74 20 6c 6f 63 | 6b 65 64 20 48 61 6e 64 | Get loc|ked Hand|
|000023d0| 6c 65 20 74 6f 20 44 49 | 54 4c 20 74 6f 20 62 65 |le to DI|TL to be|
|000023e0| 20 61 70 70 65 6e 64 65 | 64 2e 0d 20 37 2e 20 43 | appende|d.. 7. C|
|000023f0| 61 6c 63 75 6c 61 74 65 | 20 63 6f 75 6e 74 20 6f |alculate| count o|
|00002400| 66 20 6e 65 77 20 69 74 | 65 6d 73 2e 0d 7d 0d 09 |f new it|ems..}..|
|00002410| 09 6d 61 78 52 65 63 74 | 20 3a 3d 20 44 69 61 6c |.maxRect| := Dial|
|00002420| 6f 67 50 65 65 6b 28 74 | 68 65 44 69 61 6c 6f 67 |ogPeek(t|heDialog|
|00002430| 29 5e 2e 77 69 6e 64 6f | 77 2e 70 6f 72 74 2e 70 |)^.windo|w.port.p|
|00002440| 6f 72 74 52 65 63 74 3b | 0d 09 09 6f 66 66 73 65 |ortRect;|...offse|
|00002450| 74 2e 76 20 3a 3d 20 6d | 61 78 52 65 63 74 2e 62 |t.v := m|axRect.b|
|00002460| 6f 74 74 6f 6d 3b 0d 09 | 09 6f 66 66 73 65 74 2e |ottom;..|.offset.|
|00002470| 68 20 3a 3d 20 30 3b 0d | 09 09 6d 61 78 52 65 63 |h := 0;.|..maxRec|
|00002480| 74 2e 62 6f 74 74 6f 6d | 20 3a 3d 20 6d 61 78 52 |t.bottom| := maxR|
|00002490| 65 63 74 2e 62 6f 74 74 | 6f 6d 20 2d 20 35 3b 0d |ect.bott|om - 5;.|
|000024a0| 09 09 6d 61 78 52 65 63 | 74 2e 72 69 67 68 74 20 |..maxRec|t.right |
|000024b0| 3a 3d 20 6d 61 78 52 65 | 63 74 2e 72 69 67 68 74 |:= maxRe|ct.right|
|000024c0| 20 2d 20 35 3b 0d 09 09 | 68 49 74 65 6d 73 20 3a | - 5;...|hItems :|
|000024d0| 3d 20 68 49 74 65 6d 4c | 69 73 74 28 44 69 61 6c |= hItemL|ist(Dial|
|000024e0| 6f 67 50 65 65 6b 28 74 | 68 65 44 69 61 6c 6f 67 |ogPeek(t|heDialog|
|000024f0| 29 5e 2e 69 74 65 6d 73 | 29 3b 0d 09 09 66 69 72 |)^.items|);...fir|
|00002500| 73 74 49 74 65 6d 20 3a | 3d 20 68 49 74 65 6d 73 |stItem :|= hItems|
|00002510| 5e 5e 2e 64 6c 67 4d 61 | 78 49 6e 64 65 78 20 2b |^^.dlgMa|xIndex +|
|00002520| 20 32 3b 0d 09 09 68 44 | 49 54 4c 20 3a 3d 20 68 | 2;...hD|ITL := h|
|00002530| 49 74 65 6d 4c 69 73 74 | 28 47 65 74 52 65 73 6f |ItemList|(GetReso|
|00002540| 75 72 63 65 28 27 44 49 | 54 4c 27 2c 74 68 65 44 |urce('DI|TL',theD|
|00002550| 49 54 4c 49 44 29 29 3b | 0d 09 09 48 4c 6f 63 6b |ITLID));|...HLock|
|00002560| 28 48 61 6e 64 6c 65 28 | 68 44 49 54 4c 29 29 3b |(Handle(|hDITL));|
|00002570| 0d 09 09 6e 65 77 49 74 | 65 6d 73 20 3a 3d 20 68 |...newIt|ems := h|
|00002580| 44 49 54 4c 5e 5e 2e 64 | 6c 67 4d 61 78 49 6e 64 |DITL^^.d|lgMaxInd|
|00002590| 65 78 20 2b 20 31 3b 0d | 7b 0d 20 46 6f 72 20 65 |ex + 1;.|{. For e|
|000025a0| 61 63 68 20 69 74 65 6d | 2c 0d 20 20 31 2e 20 4f |ach item|,. 1. O|
|000025b0| 66 66 73 65 74 20 74 68 | 65 20 72 65 63 74 61 6e |ffset th|e rectan|
|000025c0| 67 6c 65 20 74 6f 20 66 | 6f 6c 6c 6f 77 20 74 68 |gle to f|ollow th|
|000025d0| 65 20 6f 72 69 67 69 6e | 61 6c 20 77 69 6e 64 6f |e origin|al windo|
|000025e0| 77 2e 0d 20 20 32 2e 20 | 4d 61 6b 65 20 74 68 65 |w.. 2. |Make the|
|000025f0| 20 6f 72 69 67 69 6e 61 | 6c 20 77 69 6e 64 6f 77 | origina|l window|
|00002600| 20 6c 61 72 67 65 72 20 | 69 66 20 6e 65 63 65 73 | larger |if neces|
|00002610| 73 61 72 79 2e 0d 20 20 | 33 2e 20 66 69 6c 6c 20 |sary.. |3. fill |
|00002620| 69 6e 20 69 74 65 6d 20 | 48 61 6e 64 6c 65 20 61 |in item |Handle a|
|00002630| 63 63 6f 72 64 69 6e 67 | 20 74 6f 20 74 79 70 65 |ccording| to type|
|00002640| 2e 0d 7d 0d 09 09 70 49 | 74 65 6d 20 3a 3d 20 40 |..}...pI|tem := @|
|00002650| 68 44 49 54 4c 5e 5e 2e | 44 49 54 4c 49 74 65 6d |hDITL^^.|DITLItem|
|00002660| 73 3b 0d 09 09 46 4f 52 | 20 69 20 3a 3d 20 31 20 |s;...FOR| i := 1 |
|00002670| 54 4f 20 6e 65 77 49 74 | 65 6d 73 20 44 4f 20 42 |TO newIt|ems DO B|
|00002680| 45 47 49 4e 0d 09 09 09 | 4f 66 66 73 65 74 52 65 |EGIN....|OffsetRe|
|00002690| 63 74 28 70 49 74 65 6d | 5e 2e 69 74 6d 52 65 63 |ct(pItem|^.itmRec|
|000026a0| 74 2c 6f 66 66 73 65 74 | 2e 68 2c 6f 66 66 73 65 |t,offset|.h,offse|
|000026b0| 74 2e 76 29 3b 0d 09 09 | 09 55 6e 69 6f 6e 52 65 |t.v);...|.UnionRe|
|000026c0| 63 74 28 70 49 74 65 6d | 5e 2e 69 74 6d 52 65 63 |ct(pItem|^.itmRec|
|000026d0| 74 2c 6d 61 78 52 65 63 | 74 2c 6d 61 78 52 65 63 |t,maxRec|t,maxRec|
|000026e0| 74 29 3b 0d 09 09 09 55 | 53 42 2e 49 6e 74 20 3a |t);....U|SB.Int :|
|000026f0| 3d 20 30 3b 09 09 20 7b | 7a 65 72 6f 20 74 68 69 |= 0;.. {|zero thi|
|00002700| 6e 67 73 20 6f 75 74 7d | 0d 09 09 09 55 53 42 2e |ngs out}|....USB.|
|00002710| 53 42 41 72 72 61 79 5b | 31 5d 20 3a 3d 20 70 49 |SBArray[|1] := pI|
|00002720| 74 65 6d 5e 2e 69 74 6d | 44 61 74 61 5b 30 5d 3b |tem^.itm|Data[0];|
|00002730| 0d 09 09 09 7b 20 53 74 | 72 69 70 20 65 6e 61 62 |....{ St|rip enab|
|00002740| 6c 65 20 62 69 74 20 73 | 69 6e 63 65 20 69 74 20 |le bit s|ince it |
|00002750| 64 6f 65 73 6e d5 74 20 | 6d 61 74 74 65 72 20 68 |doesn.t |matter h|
|00002760| 65 72 65 2e 20 7d 0d 09 | 09 09 57 49 54 48 20 70 |ere. }..|..WITH p|
|00002770| 49 74 65 6d 5e 20 44 4f | 0d 09 09 09 09 43 41 53 |Item^ DO|.....CAS|
|00002780| 45 20 42 41 4e 44 28 69 | 74 6d 54 79 70 65 2c 24 |E BAND(i|tmType,$|
|00002790| 37 46 29 20 4f 46 0d 09 | 09 09 09 09 7b 20 43 61 |7F) OF..|....{ Ca|
|000027a0| 6e d5 74 20 64 6f 20 61 | 6e 79 74 68 69 6e 67 20 |n.t do a|nything |
|000027b0| 77 69 74 68 20 75 73 65 | 72 20 69 74 65 6d 73 2e |with use|r items.|
|000027c0| 20 7d 0d 09 09 09 09 09 | 75 73 65 72 49 74 65 6d | }......|userItem|
|000027d0| 3a 09 20 0d 09 09 09 09 | 09 09 69 74 6d 48 6e 64 |:. .....|..itmHnd|
|000027e0| 6c 20 3a 3d 20 4e 49 4c | 3b 0d 09 09 09 09 09 09 |l := NIL|;.......|
|000027f0| 63 74 72 6c 49 74 65 6d | 20 2b 20 62 74 6e 43 74 |ctrlItem| + btnCt|
|00002800| 72 6c 2c 63 74 72 6c 49 | 74 65 6d 20 2b 20 09 09 |rl,ctrlI|tem + ..|
|00002810| 09 09 09 09 09 63 68 6b | 43 74 72 6c 2c 63 74 72 |.....chk|Ctrl,ctr|
|00002820| 6c 49 74 65 6d 20 2b 20 | 72 61 64 43 74 72 6c 3a |lItem + |radCtrl:|
|00002830| 7b 62 75 69 6c 64 20 09 | 09 09 09 09 09 09 43 6f |{build .|......Co|
|00002840| 6e 74 72 6f 6c 29 0d 09 | 09 09 09 09 09 09 69 74 |ntrol)..|......it|
|00002850| 6d 48 6e 64 6c 20 3a 3d | 20 48 61 6e 64 6c 65 28 |mHndl :=| Handle(|
|00002860| 4e 65 77 43 6f 6e 74 72 | 6f 6c 28 74 68 65 44 69 |NewContr|ol(theDi|
|00002870| 61 6c 6f 67 2c 20 7b 20 | 74 68 65 57 69 6e 64 6f |alog, { |theWindo|
|00002880| 77 20 7d 0d 09 09 09 09 | 09 09 09 09 09 09 09 09 |w }.....|........|
|00002890| 09 09 09 09 20 20 69 74 | 6d 52 65 63 74 2c 20 7b |.... it|mRect, {|
|000028a0| 20 62 6f 75 6e 64 73 52 | 65 63 74 20 7d 0d 09 09 | boundsR|ect }...|
|000028b0| 09 09 09 09 09 09 09 09 | 09 09 09 09 09 09 20 20 |........|...... |
|000028c0| 53 74 72 69 6e 67 50 74 | 72 28 40 69 74 6d 44 61 |StringPt|r(@itmDa|
|000028d0| 74 61 5b 30 5d 29 5e 2c | 20 7b 20 74 69 74 6c 65 |ta[0])^,| { title|
|000028e0| 20 7d 0d 09 09 09 09 09 | 09 09 09 09 09 09 09 09 | }......|........|
|000028f0| 09 09 09 20 20 74 72 75 | 65 2c 20 7b 20 76 69 73 |... tru|e, { vis|
|00002900| 69 62 6c 65 20 7d 0d 09 | 09 09 09 09 09 09 09 09 |ible }..|........|
|00002910| 09 09 09 09 09 09 09 20 | 20 30 2c 30 2c 31 2c 20 |....... | 0,0,1, |
|00002920| 7b 20 76 61 6c 75 65 2c | 20 6d 69 6e 2c 20 6d 61 |{ value,| min, ma|
|00002930| 78 20 7d 0d 09 09 09 09 | 09 09 09 09 09 09 09 09 |x }.....|........|
|00002940| 09 09 09 09 20 20 42 41 | 4e 44 28 69 74 6d 54 79 |.... BA|ND(itmTy|
|00002950| 70 65 2c 24 30 33 29 2c | 20 7b 20 70 72 6f 63 49 |pe,$03),| { procI|
|00002960| 44 20 7d 0d 09 09 09 09 | 09 09 09 09 09 09 09 09 |D }.....|........|
|00002970| 09 09 09 09 20 20 30 29 | 29 3b 20 7b 20 72 65 66 |.... 0)|); { ref|
|00002980| 43 6f 6e 20 7d 0d 09 09 | 09 09 09 09 63 74 72 6c |Con }...|....ctrl|
|00002990| 49 74 65 6d 20 2b 20 72 | 65 73 43 74 72 6c 3a 20 |Item + r|esCtrl: |
|000029a0| 42 45 47 49 4e 20 7b 20 | 47 65 74 20 72 65 73 6f |BEGIN { |Get reso|
|000029b0| 75 72 63 65 20 09 09 09 | 09 09 09 62 61 73 65 64 |urce ...|...based|
|000029c0| 20 43 6f 6e 74 72 6f 6c | 20 7d 0d 09 09 09 09 09 | Control| }......|
|000029d0| 09 09 69 74 6d 48 6e 64 | 6c 20 3a 3d 20 48 61 6e |..itmHnd|l := Han|
|000029e0| 64 6c 65 28 47 65 74 4e | 65 77 43 6f 6e 74 72 6f |dle(GetN|ewContro|
|000029f0| 6c 28 49 6e 74 50 74 72 | 28 40 69 74 6d 44 61 74 |l(IntPtr|(@itmDat|
|00002a00| 61 5b 31 5d 29 5e 2c 20 | 7b 20 63 6f 6e 74 72 6f |a[1])^, |{ contro|
|00002a10| 6c 49 44 20 7d 0d 09 09 | 09 09 09 09 09 09 09 09 |lID }...|........|
|00002a20| 09 09 09 09 09 09 09 20 | 20 74 68 65 44 69 61 6c |....... | theDial|
|00002a30| 6f 67 29 29 3b 20 7b 20 | 74 68 65 57 69 6e 64 6f |og)); { |theWindo|
|00002a40| 77 20 7d 0d 09 09 09 09 | 09 09 09 43 6f 6e 74 72 |w }.....|...Contr|
|00002a50| 6f 6c 48 61 6e 64 6c 65 | 28 69 74 6d 48 6e 64 6c |olHandle|(itmHndl|
|00002a60| 29 5e 5e 2e 63 6f 6e 74 | 72 6c 52 65 63 74 20 3a |)^^.cont|rlRect :|
|00002a70| 3d 20 69 74 6d 52 65 63 | 74 3b 20 7b 67 69 76 65 |= itmRec|t; {give|
|00002a80| 20 69 74 20 74 68 65 20 | 72 69 67 68 74 0d 09 09 | it the |right...|
|00002a90| 09 09 09 09 09 09 09 09 | 09 09 09 09 09 09 09 09 |........|........|
|00002aa0| 09 09 09 09 09 20 72 65 | 63 74 61 6e 67 6c 65 7d |..... re|ctangle}|
|00002ab0| 0d 09 09 09 09 09 09 09 | 7b 41 6e 20 61 63 74 69 |........|{An acti|
|00002ac0| 6f 6e 50 72 6f 63 20 66 | 6f 72 20 61 20 43 6f 6e |onProc f|or a Con|
|00002ad0| 74 72 6f 6c 20 09 09 09 | 09 09 09 09 20 73 68 6f |trol ...|.... sho|
|00002ae0| 75 6c 64 20 62 65 20 69 | 6e 73 74 61 6c 6c 65 64 |uld be i|nstalled|
|00002af0| 20 68 65 72 65 7d 0d 09 | 09 09 09 09 09 45 4e 44 | here}..|.....END|
|00002b00| 3b 09 09 09 20 7b 43 61 | 73 65 20 63 74 72 6c 49 |;... {Ca|se ctrlI|
|00002b10| 74 65 6d 20 2b 20 09 09 | 09 09 09 09 09 09 09 20 |tem + ..|....... |
|00002b20| 20 72 65 73 43 74 72 6c | 7d 0d 09 09 09 09 09 09 | resCtrl|}.......|
|00002b30| 73 74 61 74 54 65 78 74 | 2c 65 64 69 74 54 65 78 |statText|,editTex|
|00002b40| 74 3a 20 7b 20 42 6f 74 | 68 20 6e 65 65 64 20 48 |t: { Bot|h need H|
|00002b50| 61 6e 64 6c 65 20 74 6f | 20 09 09 09 09 09 09 09 |andle to| .......|
|00002b60| 09 20 20 20 20 20 20 20 | 61 20 63 6f 70 79 20 6f |. |a copy o|
|00002b70| 66 20 74 68 65 69 72 20 | 09 09 09 09 09 09 09 09 |f their |........|
|00002b80| 09 74 65 78 74 2e 20 7d | 0d 09 09 09 09 09 09 09 |.text. }|........|
|00002b90| 65 72 72 20 3a 3d 20 50 | 74 72 54 6f 48 61 6e 64 |err := P|trToHand|
|00002ba0| 28 40 69 74 6d 44 61 74 | 61 5b 31 5d 2c 20 09 09 |(@itmDat|a[1], ..|
|00002bb0| 09 09 09 09 09 28 20 53 | 74 61 72 74 20 6f 66 20 |.....( S|tart of |
|00002bc0| 64 61 74 61 20 7d 0d 09 | 09 09 09 09 09 09 09 09 |data }..|........|
|00002bd0| 09 09 09 20 20 69 74 6d | 48 6e 64 6c 2c 20 7b 20 |... itm|Hndl, { |
|00002be0| 41 64 64 72 65 73 73 20 | 6f 66 20 6e 65 77 20 48 |Address |of new H|
|00002bf0| 61 6e 64 6c 65 20 7d 0d | 09 09 09 09 09 09 09 09 |andle }.|........|
|00002c00| 09 09 09 09 20 20 55 53 | 42 2e 49 6e 74 29 3b 20 |.... US|B.Int); |
|00002c10| 7b 20 4c 65 6e 67 74 68 | 20 6f 66 20 74 65 78 74 |{ Length| of text|
|00002c20| 20 7d 0d 09 09 09 09 09 | 09 69 63 6f 6e 49 74 65 | }......|.iconIte|
|00002c30| 6d 3a 09 20 7b 20 49 63 | 6f 6e 20 6e 65 65 64 73 |m:. { Ic|on needs|
|00002c40| 20 72 65 73 6f 75 72 63 | 65 20 09 09 09 09 09 09 | resourc|e ......|
|00002c50| 09 09 20 20 20 48 61 6e | 64 6c 65 2e 20 7d 0d 09 |.. Han|dle. }..|
|00002c60| 09 09 09 09 09 09 70 49 | 74 65 6d 5e 2e 69 74 6d |......pI|tem^.itm|
|00002c70| 48 6e 64 6c 20 3a 3d 20 | 47 65 74 49 63 6f 6e 28 |Hndl := |GetIcon(|
|00002c80| 49 6e 74 50 74 72 28 40 | 69 74 6d 44 61 74 61 5b |IntPtr(@|itmData[|
|00002c90| 31 5d 29 5e 29 3b 20 7b | 20 49 43 4f 4e 20 72 65 |1])^); {| ICON re|
|00002ca0| 73 49 44 20 7d 0d 09 09 | 09 09 09 09 70 69 63 49 |sID }...|....picI|
|00002cb0| 74 65 6d 3a 20 09 20 7b | 20 50 69 63 74 75 72 65 |tem: . {| Picture|
|00002cc0| 20 6e 65 65 64 73 20 72 | 65 73 6f 75 72 63 65 20 | needs r|esource |
|00002cd0| 09 09 09 09 09 09 09 09 | 20 20 20 48 61 6e 64 6c |........| Handl|
|00002ce0| 65 2e 20 7d 0d 09 09 09 | 09 09 09 09 70 49 74 65 |e. }....|....pIte|
|00002cf0| 6d 5e 2e 69 74 6d 48 6e | 64 6c 20 3a 3d 20 48 61 |m^.itmHn|dl := Ha|
|00002d00| 6e 64 6c 65 28 47 65 74 | 50 69 63 74 75 72 65 28 |ndle(Get|Picture(|
|00002d10| 49 6e 74 50 74 72 28 40 | 69 74 6d 44 61 74 61 5b |IntPtr(@|itmData[|
|00002d20| 31 5d 29 5e 29 29 3b 7b | 50 49 43 54 20 72 65 73 |1])^));{|PICT res|
|00002d30| 49 44 7d 0d 09 09 09 09 | 09 09 4f 54 48 45 52 57 |ID}.....|..OTHERW|
|00002d40| 49 53 45 0d 09 09 09 09 | 09 09 09 69 74 6d 48 6e |ISE.....|...itmHn|
|00002d50| 64 6c 20 3a 3d 20 4e 49 | 4c 3b 0d 09 09 09 09 09 |dl := NI|L;......|
|00002d60| 45 4e 44 3b 09 09 09 09 | 20 7b 43 61 73 65 7d 0d |END;....| {Case}.|
|00002d70| 09 09 09 09 64 61 74 61 | 53 69 7a 65 20 3a 3d 20 |....data|Size := |
|00002d80| 42 41 4e 44 28 55 53 42 | 2e 49 6e 74 20 2b 20 31 |BAND(USB|.Int + 1|
|00002d90| 2c 24 46 46 46 45 29 3b | 0d 09 09 09 09 7b 6e 6f |,$FFFE);|.....{no|
|00002da0| 77 20 61 64 76 61 6e 63 | 65 20 74 6f 20 6e 65 78 |w advanc|e to nex|
|00002db0| 74 20 69 74 65 6d 7d 0d | 09 09 09 09 70 49 74 65 |t item}.|....pIte|
|00002dc0| 6d 20 3a 3d 20 70 44 49 | 54 4c 49 74 65 6d 28 50 |m := pDI|TLItem(P|
|00002dd0| 74 72 28 6f 72 64 34 28 | 40 70 49 74 65 6d 5e 29 |tr(ord4(|@pItem^)|
|00002de0| 20 2b 20 64 61 74 61 53 | 69 7a 65 20 2b 20 09 09 | + dataS|ize + ..|
|00002df0| 09 09 73 69 7a 65 6f 66 | 28 44 49 54 4c 49 74 65 |..sizeof|(DITLIte|
|00002e00| 6d 29 29 29 3b 0d 09 09 | 09 45 4e 44 3b 09 09 09 |m)));...|.END;...|
|00002e10| 09 09 09 20 7b 66 6f 72 | 7d 0d 09 09 09 65 72 72 |... {for|}....err|
|00002e20| 20 3a 3d 20 50 74 72 41 | 6e 64 48 61 6e 64 0d 20 | := PtrA|ndHand. |
|00002e30| 09 09 09 28 40 68 44 49 | 54 4c 5e 5e 2e 44 49 54 |...(@hDI|TL^^.DIT|
|00002e40| 4c 49 74 65 6d 73 2c 48 | 61 6e 64 6c 65 28 68 49 |LItems,H|andle(hI|
|00002e50| 74 65 6d 73 29 2c 47 65 | 74 48 61 6e 64 6c 65 53 |tems),Ge|tHandleS|
|00002e60| 69 7a 65 28 48 61 6e 64 | 6c 65 28 68 44 49 54 4c |ize(Hand|le(hDITL|
|00002e70| 29 29 29 3b 0d 09 09 09 | 68 49 74 65 6d 73 5e 5e |)));....|hItems^^|
|00002e80| 2e 64 6c 67 4d 61 78 49 | 6e 64 65 78 20 3a 3d 20 |.dlgMaxI|ndex := |
|00002e90| 68 49 74 65 6d 73 5e 5e | 2e 64 6c 67 4d 61 78 49 |hItems^^|.dlgMaxI|
|00002ea0| 6e 64 65 78 20 2b 20 6e | 65 77 49 74 65 6d 73 3b |ndex + n|ewItems;|
|00002eb0| 0d 09 09 09 48 55 6e 6c | 6f 63 6b 28 48 61 6e 64 |....HUnl|ock(Hand|
|00002ec0| 6c 65 28 68 44 49 54 4c | 29 29 3b 0d 09 09 09 52 |le(hDITL|));....R|
|00002ed0| 65 6c 65 61 73 65 52 65 | 73 6f 75 72 63 65 28 48 |eleaseRe|source(H|
|00002ee0| 61 6e 64 6c 65 28 68 44 | 49 54 4c 29 29 3b 0d 09 |andle(hD|ITL));..|
|00002ef0| 09 09 6d 61 78 52 65 63 | 74 2e 62 6f 74 74 6f 6d |..maxRec|t.bottom|
|00002f00| 20 3a 3d 20 6d 61 78 52 | 65 63 74 2e 62 6f 74 74 | := maxR|ect.bott|
|00002f10| 6f 6d 20 2b 20 35 3b 0d | 09 09 09 6d 61 78 52 65 |om + 5;.|...maxRe|
|00002f20| 63 74 2e 72 69 67 68 74 | 20 3a 3d 20 6d 61 78 52 |ct.right| := maxR|
|00002f30| 65 63 74 2e 72 69 67 68 | 74 20 2b 20 35 3b 0d 09 |ect.righ|t + 5;..|
|00002f40| 09 09 53 69 7a 65 57 69 | 6e 64 6f 77 28 74 68 65 |..SizeWi|ndow(the|
|00002f50| 44 69 61 6c 6f 67 2c 6d | 61 78 52 65 63 74 2e 72 |Dialog,m|axRect.r|
|00002f60| 69 67 68 74 2c 6d 61 78 | 52 65 63 74 2e 62 6f 74 |ight,max|Rect.bot|
|00002f70| 74 6f 6d 2c 74 72 75 65 | 29 3b 0d 09 09 09 41 70 |tom,true|);....Ap|
|00002f80| 70 65 6e 64 44 49 54 4c | 20 3a 3d 20 66 69 72 73 |pendDITL| := firs|
|00002f90| 74 49 74 65 6d 3b 0d 09 | 09 45 4e 44 3b 09 09 09 |tItem;..|.END;...|
|00002fa0| 09 09 09 09 20 7b 41 70 | 70 65 6e 64 44 49 54 4c |.... {Ap|pendDITL|
|00002fb0| 7d 0d 09 7b 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |}..{----|--------|
|00002fc0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002fd0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002fe0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00002ff0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 7d 0d 09 50 |--------|----}..P|
|00003000| 52 4f 43 45 44 55 52 45 | 20 4d 79 4a 6f 62 49 74 |ROCEDURE| MyJobIt|
|00003010| 65 6d 73 28 74 68 65 44 | 69 61 6c 6f 67 3a 20 44 |ems(theD|ialog: D|
|00003020| 69 61 6c 6f 67 50 74 72 | 3b 20 69 74 65 6d 4e 6f |ialogPtr|; itemNo|
|00003030| 3a 20 49 6e 74 65 67 65 | 72 29 3b 0d 20 7b 20 0d |: Intege|r);. { .|
|00003040| 20 54 68 69 73 20 72 6f | 75 74 69 6e 65 20 72 65 | This ro|utine re|
|00003050| 70 6c 61 63 65 73 20 74 | 68 65 20 72 6f 75 74 69 |places t|he routi|
|00003060| 6e 65 20 69 6e 20 74 68 | 65 20 70 49 74 65 6d 50 |ne in th|e pItemP|
|00003070| 72 6f 63 20 66 69 65 6c | 64 20 69 6e 20 74 68 65 |roc fiel|d in the|
|00003080| 0d 09 54 50 50 72 44 6c | 67 20 72 65 63 6f 72 64 |..TPPrDl|g record|
|00003090| 2e 20 20 54 68 65 20 73 | 74 65 70 73 20 69 74 20 |. The s|teps it |
|000030a0| 74 61 6b 65 73 20 61 72 | 65 3a 0d 09 31 2e 20 43 |takes ar|e:..1. C|
|000030b0| 68 65 63 6b 20 74 6f 20 | 73 65 65 20 69 66 20 74 |heck to |see if t|
|000030c0| 68 65 20 69 74 65 6d 20 | 68 69 74 20 77 61 73 20 |he item |hit was |
|000030d0| 6f 6e 65 20 6f 66 20 6f | 75 72 73 2e 20 54 68 69 |one of o|urs. Thi|
|000030e0| 73 20 69 73 20 64 6f 6e | 65 20 62 79 20 d2 6c 6f |s is don|e by .lo|
|000030f0| 63 61 6c 69 7a 69 6e 67 | d3 0d 09 09 20 20 74 68 |calizing|.... th|
|00003100| 65 20 6e 75 6d 62 65 72 | 2c 20 61 73 73 75 6d 69 |e number|, assumi|
|00003110| 6e 67 20 74 68 61 74 20 | 6f 75 72 20 69 74 65 6d |ng that |our item|
|00003120| 73 20 61 72 65 20 6e 75 | 6d 62 65 72 65 64 20 66 |s are nu|mbered f|
|00003130| 72 6f 6d 20 30 2e 2e 6e | 0d 09 32 2e 20 49 66 20 |rom 0..n|..2. If |
|00003140| 69 74 d5 73 20 6f 6e 65 | 20 6f 66 20 6f 75 72 73 |it.s one| of ours|
|00003150| 20 20 74 68 65 6e 20 63 | 61 73 65 20 69 74 20 61 | then c|ase it a|
|00003160| 6e 64 20 48 61 6e 64 6c | 65 20 61 70 70 72 6f 70 |nd Handl|e approp|
|00003170| 72 69 61 74 65 6c 79 0d | 09 33 2e 20 49 66 20 69 |riately.|.3. If i|
|00003180| 74 20 69 73 6e d5 74 20 | 6f 6e 65 20 6f 66 20 6f |t isn.t |one of o|
|00003190| 75 72 73 20 74 68 65 6e | 20 63 61 6c 6c 20 74 68 |urs then| call th|
|000031a0| 65 20 6f 6c 64 20 69 74 | 65 6d 20 68 61 6e 64 6c |e old it|em handl|
|000031b0| 65 72 0d 20 7d 0d 09 09 | 56 41 52 0d 09 09 09 4d |er. }...|VAR....M|
|000031c0| 79 49 74 65 6d 2c 66 69 | 72 73 74 49 74 65 6d 3a |yItem,fi|rstItem:|
|000031d0| 20 49 6e 74 65 67 65 72 | 3b 0d 09 09 09 74 68 65 | Integer|;....the|
|000031e0| 50 74 20 09 09 3a 20 50 | 6f 69 6e 74 3b 0d 09 09 |Pt ..: P|oint;...|
|000031f0| 09 74 68 65 50 61 72 74 | 09 09 3a 20 49 6e 74 65 |.thePart|..: Inte|
|00003200| 67 65 72 3b 0d 09 09 09 | 74 68 65 56 61 6c 75 65 |ger;....|theValue|
|00003210| 20 09 3a 20 49 6e 74 65 | 67 65 72 3b 0d 09 09 09 | .: Inte|ger;....|
|00003220| 64 65 62 75 67 50 61 72 | 74 09 3a 20 49 6e 74 65 |debugPar|t.: Inte|
|00003230| 67 65 72 3b 0d 09 09 42 | 45 47 49 4e 20 09 09 09 |ger;...B|EGIN ...|
|00003240| 09 09 09 20 7b 4d 79 4a | 6f 62 49 74 65 6d 73 7d |... {MyJ|obItems}|
|00003250| 0d 09 09 09 66 69 72 73 | 74 49 74 65 6d 20 3a 3d |....firs|tItem :=|
|00003260| 20 70 72 46 69 72 73 74 | 49 74 65 6d 3b 20 7b 20 | prFirst|Item; { |
|00003270| 72 65 6d 65 6d 62 65 72 | 2c 20 77 65 20 73 61 76 |remember|, we sav|
|00003280| 65 64 20 74 68 69 73 20 | 69 6e 20 09 09 09 09 09 |ed this |in .....|
|00003290| 09 09 20 20 20 20 20 20 | 20 6d 79 4a 6f 62 44 6c |.. | myJobDl|
|000032a0| 67 49 6e 69 74 20 7d 0d | 09 09 09 4d 79 49 74 65 |gInit }.|...MyIte|
|000032b0| 6d 20 3a 3d 20 69 74 65 | 6d 4e 6f 20 2d 20 66 69 |m := ite|mNo - fi|
|000032c0| 72 73 74 49 74 65 6d 20 | 2b 20 31 3b 20 7b 20 d2 |rstItem |+ 1; { .|
|000032d0| 6c 6f 63 61 6c 69 7a 65 | d3 20 63 75 72 72 65 6e |localize|. curren|
|000032e0| 74 20 69 74 65 6d 20 4e | 6f 20 7d 0d 09 09 09 49 |t item N|o }....I|
|000032f0| 46 20 4d 79 49 74 65 6d | 20 3e 20 30 20 54 48 45 |F MyItem| > 0 THE|
|00003300| 4e 20 42 45 47 49 4e 20 | 7b 20 69 66 20 6c 6f 63 |N BEGIN |{ if loc|
|00003310| 61 6c 69 7a 65 64 20 69 | 74 65 6d 20 3e 20 30 2c |alized i|tem > 0,|
|00003320| 20 69 74 d5 73 20 6f 6e | 65 20 6f 66 20 09 09 09 | it.s on|e of ...|
|00003330| 09 09 09 20 20 20 20 20 | 20 6f 75 72 73 20 7d 0d |... | ours }.|
|00003340| 09 09 09 09 7b 20 66 69 | 6e 64 20 6f 75 74 20 77 |....{ fi|nd out w|
|00003350| 68 69 63 68 20 6f 66 20 | 6f 75 72 20 69 74 65 6d |hich of |our item|
|00003360| 73 20 77 61 73 20 68 69 | 74 20 7d 0d 09 09 09 09 |s was hi|t }.....|
|00003370| 47 65 74 44 49 74 65 6d | 28 74 68 65 44 69 61 6c |GetDItem|(theDial|
|00003380| 6f 67 2c 69 74 65 6d 4e | 6f 2c 69 74 65 6d 54 79 |og,itemN|o,itemTy|
|00003390| 70 65 2c 69 74 65 6d 48 | 2c 69 74 65 6d 42 6f 78 |pe,itemH|,itemBox|
|000033a0| 29 3b 0d 09 09 09 09 43 | 41 53 45 20 4d 79 49 74 |);.....C|ASE MyIt|
|000033b0| 65 6d 20 4f 46 0d 09 09 | 09 09 09 4d 79 44 46 69 |em OF...|...MyDFi|
|000033c0| 72 73 74 42 6f 78 3a 20 | 42 45 47 49 4e 0d 09 09 |rstBox: |BEGIN...|
|000033d0| 09 09 09 09 7b 20 69 6e | 76 65 72 74 20 76 61 6c |....{ in|vert val|
|000033e0| 75 65 20 6f 66 20 46 69 | 72 73 74 42 6f 78 56 61 |ue of Fi|rstBoxVa|
|000033f0| 6c 75 65 20 61 6e 64 20 | 09 09 09 09 09 09 20 20 |lue and |...... |
|00003400| 20 72 65 64 72 61 77 20 | 69 74 20 7d 0d 09 09 09 | redraw |it }....|
|00003410| 09 09 09 46 69 72 73 74 | 42 6f 78 56 61 6c 75 65 |...First|BoxValue|
|00003420| 20 3a 3d 20 31 20 2d 20 | 46 69 72 73 74 42 6f 78 | := 1 - |FirstBox|
|00003430| 56 61 6c 75 65 3b 0d 09 | 09 09 09 09 09 53 65 74 |Value;..|.....Set|
|00003440| 43 74 6c 56 61 6c 75 65 | 28 43 6f 6e 74 72 6f 6c |CtlValue|(Control|
|00003450| 48 61 6e 64 6c 65 28 69 | 74 65 6d 48 29 2c 46 69 |Handle(i|temH),Fi|
|00003460| 72 73 74 42 6f 78 56 61 | 6c 75 65 29 3b 0d 09 09 |rstBoxVa|lue);...|
|00003470| 09 09 09 45 4e 44 3b 09 | 09 09 09 20 7b 63 61 73 |...END;.|... {cas|
|00003480| 65 20 4d 79 44 46 69 72 | 73 74 42 6f 78 7d 0d 09 |e MyDFir|stBox}..|
|00003490| 09 09 09 09 4d 79 44 53 | 65 63 6f 6e 64 42 6f 78 |....MyDS|econdBox|
|000034a0| 3a 20 42 45 47 49 4e 0d | 09 09 09 09 09 09 7b 20 |: BEGIN.|......{ |
|000034b0| 69 6e 76 65 72 74 20 76 | 61 6c 75 65 20 6f 66 20 |invert v|alue of |
|000034c0| 53 65 63 6f 6e 64 42 6f | 78 56 61 6c 75 65 20 61 |SecondBo|xValue a|
|000034d0| 6e 64 20 09 09 09 09 09 | 09 20 20 72 65 64 72 61 |nd .....|. redra|
|000034e0| 77 20 69 74 20 7d 0d 09 | 09 09 09 09 09 53 65 63 |w it }..|.....Sec|
|000034f0| 6f 6e 64 42 6f 78 56 61 | 6c 75 65 20 3a 3d 20 31 |ondBoxVa|lue := 1|
|00003500| 20 2d 20 53 65 63 6f 6e | 64 42 6f 78 56 61 6c 75 | - Secon|dBoxValu|
|00003510| 65 3b 0d 09 09 09 09 09 | 09 53 65 74 43 74 6c 56 |e;......|.SetCtlV|
|00003520| 61 6c 75 65 28 43 6f 6e | 74 72 6f 6c 48 61 6e 64 |alue(Con|trolHand|
|00003530| 6c 65 28 69 74 65 6d 48 | 29 2c 53 65 63 6f 6e 64 |le(itemH|),Second|
|00003540| 42 6f 78 56 61 6c 75 65 | 29 3b 0d 09 09 09 09 09 |BoxValue|);......|
|00003550| 45 4e 44 3b 09 09 09 09 | 20 7b 63 61 73 65 20 09 |END;....| {case .|
|00003560| 09 09 09 09 09 09 09 09 | 09 20 20 4d 79 44 53 65 |........|. MyDSe|
|00003570| 63 6f 6e 64 42 6f 78 7d | 0d 09 09 09 09 09 4f 54 |condBox}|......OT|
|00003580| 48 45 52 57 49 53 45 0d | 09 09 09 09 09 09 44 65 |HERWISE.|......De|
|00003590| 62 75 67 3b 09 09 20 7b | 20 4f 48 20 4f 48 20 d1 |bug;.. {| OH OH .|
|000035a0| 20 57 65 20 67 6f 74 20 | 61 6e 20 69 74 65 6d 20 | We got |an item |
|000035b0| 09 09 09 09 09 09 09 20 | 20 20 20 20 20 20 20 20 |....... | |
|000035c0| 20 77 65 20 64 69 64 6e | d5 74 20 65 78 70 65 63 | we didn|.t expec|
|000035d0| 74 20 7d 0d 09 09 09 09 | 45 4e 44 3b 09 09 09 09 |t }.....|END;....|
|000035e0| 09 20 7b 43 61 73 65 7d | 0d 09 09 09 45 4e 44 09 |. {Case}|....END.|
|000035f0| 09 09 09 09 09 20 7b 20 | 69 66 20 4d 79 49 74 65 |..... { |if MyIte|
|00003600| 6d 20 3e 20 30 20 7d 0d | 09 09 09 45 4c 53 45 20 |m > 0 }.|...ELSE |
|00003610| 09 09 09 09 20 7b 20 63 | 68 61 69 6e 20 74 6f 20 |.... { c|hain to |
|00003620| 73 74 61 6e 64 61 72 64 | 20 69 74 65 6d 20 68 61 |standard| item ha|
|00003630| 6e 64 6c 65 72 2c 20 09 | 09 09 09 09 09 09 20 20 |ndler, .|...... |
|00003640| 20 77 68 6f 73 65 20 61 | 64 64 72 65 73 73 20 69 | whose a|ddress i|
|00003650| 73 20 73 61 76 65 64 20 | 09 09 09 09 09 09 09 09 |s saved |........|
|00003660| 09 09 09 09 09 09 09 09 | 09 09 69 6e 20 70 72 50 |........|..in prP|
|00003670| 49 74 65 6d 50 72 6f 63 | 20 7d 0d 09 09 09 09 43 |ItemProc| }.....C|
|00003680| 61 6c 6c 49 74 65 6d 48 | 61 6e 64 6c 65 72 28 74 |allItemH|andler(t|
|00003690| 68 65 44 69 61 6c 6f 67 | 2c 69 74 65 6d 4e 6f 2c |heDialog|,itemNo,|
|000036a0| 70 72 50 49 74 65 6d 50 | 72 6f 63 29 3b 0d 09 09 |prPItemP|roc);...|
|000036b0| 45 4e 44 3b 09 09 09 09 | 09 09 09 20 7b 20 4d 79 |END;....|... { My|
|000036c0| 4a 6f 62 49 74 65 6d 73 | 20 7d 0d 09 7b 2d 2d 2d |JobItems| }..{---|
|000036d0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000036e0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000036f0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003700| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003710| 2d 2d 2d 2d 2d 7d 0d 09 | 46 55 4e 43 54 49 4f 4e |-----}..|FUNCTION|
|00003720| 20 4d 79 4a 6f 62 44 6c | 67 49 6e 69 74 28 68 50 | MyJobDl|gInit(hP|
|00003730| 72 69 6e 74 3a 20 54 48 | 50 72 69 6e 74 29 3a 20 |rint: TH|Print): |
|00003740| 54 50 50 72 44 6c 67 3b | 0d 7b 0d 20 54 68 69 73 |TPPrDlg;|.{. This|
|00003750| 20 72 6f 75 74 69 6e 65 | 20 61 70 70 65 6e 64 73 | routine| appends|
|00003760| 20 69 74 65 6d 73 20 74 | 6f 20 74 68 65 20 73 74 | items t|o the st|
|00003770| 61 6e 64 61 72 64 20 6a | 6f 62 20 64 69 61 6c 6f |andard j|ob dialo|
|00003780| 67 20 61 6e 64 20 73 65 | 74 73 20 75 70 20 74 68 |g and se|ts up th|
|00003790| 65 0d 20 75 73 65 72 20 | 66 69 65 6c 64 73 20 6f |e. user |fields o|
|000037a0| 66 20 74 68 65 20 70 72 | 69 6e 74 69 6e 67 20 64 |f the pr|inting d|
|000037b0| 69 61 6c 6f 67 20 72 65 | 63 6f 72 64 20 54 50 52 |ialog re|cord TPR|
|000037c0| 44 6c 67 0d 20 54 68 69 | 73 20 72 6f 75 74 69 6e |Dlg. Thi|s routin|
|000037d0| 65 20 77 69 6c 6c 20 62 | 65 20 63 61 6c 6c 65 64 |e will b|e called|
|000037e0| 20 62 79 20 50 72 44 6c | 67 4d 61 69 6e 0d 20 54 | by PrDl|gMain. T|
|000037f0| 68 69 73 20 69 73 20 77 | 68 61 74 20 69 74 20 64 |his is w|hat it d|
|00003800| 6f 65 73 3a 0d 20 31 2e | 20 46 69 72 73 74 20 63 |oes:. 1.| First c|
|00003810| 61 6c 6c 20 50 72 4a 6f | 62 49 6e 69 74 20 74 6f |all PrJo|bInit to|
|00003820| 20 66 69 6c 6c 20 69 6e | 20 74 68 65 20 54 50 50 | fill in| the TPP|
|00003830| 72 44 6c 67 20 72 65 63 | 6f 72 64 2e 0d 20 32 2e |rDlg rec|ord.. 2.|
|00003840| 20 41 70 70 65 6e 64 20 | 6f 75 72 20 69 74 65 6d | Append |our item|
|00003850| 73 20 6f 6e 74 6f 20 74 | 68 65 20 6f 6c 64 20 44 |s onto t|he old D|
|00003860| 49 54 4c 2e 20 53 65 74 | 20 74 68 65 6d 20 75 70 |ITL. Set| them up|
|00003870| 20 61 70 70 72 6f 70 72 | 69 61 74 65 6c 79 2e 0d | appropr|iately..|
|00003880| 20 33 2e 20 53 61 76 65 | 20 74 68 65 20 61 64 64 | 3. Save| the add|
|00003890| 72 65 73 73 20 6f 66 20 | 74 68 65 20 6f 6c 64 20 |ress of |the old |
|000038a0| 69 74 65 6d 20 68 61 6e | 64 6c 65 72 20 61 6e 64 |item han|dler and|
|000038b0| 20 72 65 70 6c 61 63 65 | 20 69 74 20 77 69 74 68 | replace| it with|
|000038c0| 20 6f 75 72 73 2e 0d 20 | 34 2e 20 52 65 74 75 72 | ours.. |4. Retur|
|000038d0| 6e 20 74 68 65 20 46 69 | 78 65 64 20 64 69 61 6c |n the Fi|xed dial|
|000038e0| 6f 67 20 74 6f 20 50 72 | 44 6c 67 4d 61 69 6e 2e |og to Pr|DlgMain.|
|000038f0| 0d 20 7d 0d 09 09 56 41 | 52 0d 09 09 09 66 69 72 |. }...VA|R....fir|
|00003900| 73 74 49 74 65 6d 09 3a | 20 49 6e 74 65 67 65 72 |stItem.:| Integer|
|00003910| 3b 20 7b 20 66 69 72 73 | 74 20 6e 65 77 20 69 74 |; { firs|t new it|
|00003920| 65 6d 20 6e 75 6d 62 65 | 72 20 7d 0d 09 09 42 45 |em numbe|r }...BE|
|00003930| 47 49 4e 20 09 09 09 09 | 09 09 20 7b 4d 79 4a 6f |GIN ....|.. {MyJo|
|00003940| 62 44 6c 67 49 6e 69 74 | 7d 0d 09 09 09 66 69 72 |bDlgInit|}....fir|
|00003950| 73 74 49 74 65 6d 20 3a | 3d 20 41 70 70 65 6e 64 |stItem :|= Append|
|00003960| 44 49 54 4c 28 44 69 61 | 6c 6f 67 50 74 72 28 50 |DITL(Dia|logPtr(P|
|00003970| 72 74 4a 6f 62 44 69 61 | 6c 6f 67 29 2c 4d 79 44 |rtJobDia|log),MyD|
|00003980| 49 54 4c 29 3b 20 0d 09 | 09 09 70 72 46 69 72 73 |ITL); ..|..prFirs|
|00003990| 74 49 74 65 6d 20 3a 3d | 20 66 69 72 73 74 49 74 |tItem :=| firstIt|
|000039a0| 65 6d 3b 20 7b 20 73 61 | 76 65 20 74 68 69 73 20 |em; { sa|ve this |
|000039b0| 73 6f 20 4d 79 4a 6f 62 | 49 74 65 6d 73 20 63 61 |so MyJob|Items ca|
|000039c0| 6e 0d 09 09 09 09 09 09 | 20 20 20 20 20 20 20 66 |n.......| f|
|000039d0| 69 6e 64 20 69 74 20 7d | 0d 09 09 09 7b 20 6e 6f |ind it }|....{ no|
|000039e0| 77 20 77 65 d5 6c 6c 20 | 73 65 74 20 75 70 20 6f |w we.ll |set up o|
|000039f0| 75 72 20 44 49 54 4c 20 | 69 74 65 6d 73 20 d1 20 |ur DITL |items . |
|00003a00| 54 68 65 20 22 46 69 72 | 73 74 20 42 6f 78 22 20 |The "Fir|st Box" |
|00003a10| 7d 0d 09 09 09 47 65 74 | 44 49 74 65 6d 28 44 69 |}....Get|DItem(Di|
|00003a20| 61 6c 6f 67 50 74 72 28 | 50 72 74 4a 6f 62 44 69 |alogPtr(|PrtJobDi|
|00003a30| 61 6c 6f 67 29 2c 66 69 | 72 73 74 49 74 65 6d 2c |alog),fi|rstItem,|
|00003a40| 69 74 65 6d 54 79 70 65 | 2c 69 74 65 6d 48 2c 69 |itemType|,itemH,i|
|00003a50| 74 65 6d 42 6f 78 29 3b | 0d 09 09 09 53 65 74 43 |temBox);|....SetC|
|00003a60| 74 6c 56 61 6c 75 65 28 | 43 6f 6e 74 72 6f 6c 48 |tlValue(|ControlH|
|00003a70| 61 6e 64 6c 65 28 69 74 | 65 6d 48 29 2c 46 69 72 |andle(it|emH),Fir|
|00003a80| 73 74 42 6f 78 56 61 6c | 75 65 29 3b 0d 09 09 09 |stBoxVal|ue);....|
|00003a90| 7b 20 6e 6f 77 20 77 65 | d5 6c 6c 20 73 65 74 20 |{ now we|.ll set |
|00003aa0| 75 70 20 74 68 65 20 73 | 65 63 6f 6e 64 20 6f 66 |up the s|econd of|
|00003ab0| 20 6f 75 72 20 44 49 54 | 4c 20 69 74 65 6d 73 20 | our DIT|L items |
|00003ac0| d1 20 54 68 65 20 22 53 | 65 63 6f 6e 64 20 09 09 |. The "S|econd ..|
|00003ad0| 09 20 20 42 6f 78 22 20 | 7d 0d 09 09 09 47 65 74 |. Box" |}....Get|
|00003ae0| 44 49 74 65 6d 28 44 69 | 61 6c 6f 67 50 74 72 28 |DItem(Di|alogPtr(|
|00003af0| 50 72 74 4a 6f 62 44 69 | 61 6c 6f 67 29 2c 66 69 |PrtJobDi|alog),fi|
|00003b00| 72 73 74 49 74 65 6d 20 | 2b 20 09 09 09 09 09 31 |rstItem |+ .....1|
|00003b10| 2c 69 74 65 6d 54 79 70 | 65 2c 69 74 65 6d 48 2c |,itemTyp|e,itemH,|
|00003b20| 69 74 65 6d 42 6f 78 29 | 3b 0d 09 09 09 53 65 74 |itemBox)|;....Set|
|00003b30| 43 74 6c 56 61 6c 75 65 | 28 43 6f 6e 74 72 6f 6c |CtlValue|(Control|
|00003b40| 48 61 6e 64 6c 65 28 69 | 74 65 6d 48 29 2c 53 65 |Handle(i|temH),Se|
|00003b50| 63 6f 6e 64 42 6f 78 56 | 61 6c 75 65 29 3b 0d 7b |condBoxV|alue);.{|
|00003b60| 20 4e 6f 77 20 63 6f 6d | 65 73 20 74 68 65 20 70 | Now com|es the p|
|00003b70| 61 72 74 20 77 68 65 72 | 65 20 77 65 20 70 61 74 |art wher|e we pat|
|00003b80| 63 68 20 69 6e 20 6f 75 | 72 20 69 74 65 6d 20 68 |ch in ou|r item h|
|00003b90| 61 6e 64 6c 65 72 2e 20 | 20 57 65 20 68 61 76 65 |andler. | We have|
|00003ba0| 20 74 6f 20 73 61 76 65 | 0d 20 74 68 65 20 6f 6c | to save|. the ol|
|00003bb0| 64 20 69 74 65 6d 20 68 | 61 6e 64 6c 65 72 20 61 |d item h|andler a|
|00003bc0| 64 64 72 65 73 73 2c 20 | 73 6f 20 77 65 20 63 61 |ddress, |so we ca|
|00003bd0| 6e 20 63 61 6c 6c 20 69 | 74 20 69 66 20 6f 6e 65 |n call i|t if one|
|00003be0| 20 6f 66 20 74 68 65 20 | 73 74 61 6e 64 61 72 64 | of the |standard|
|00003bf0| 0d 20 69 74 65 6d 73 20 | 69 73 20 68 69 74 2c 20 |. items |is hit, |
|00003c00| 61 6e 64 20 70 75 74 20 | 6f 75 72 20 69 74 65 6d |and put |our item|
|00003c10| 20 68 61 6e 64 6c 65 72 | d5 73 20 61 64 64 72 65 | handler|.s addre|
|00003c20| 73 73 0d 20 69 6e 20 70 | 49 74 65 6d 50 72 6f 63 |ss. in p|ItemProc|
|00003c30| 20 66 69 65 6c 64 20 6f | 66 20 74 68 65 20 54 50 | field o|f the TP|
|00003c40| 72 44 6c 67 20 73 74 72 | 75 63 74 7d 0d 09 09 09 |rDlg str|uct}....|
|00003c50| 70 72 50 49 74 65 6d 50 | 72 6f 63 20 3a 3d 20 4c |prPItemP|roc := L|
|00003c60| 6f 6e 67 49 6e 74 28 50 | 72 74 4a 6f 62 44 69 61 |ongInt(P|rtJobDia|
|00003c70| 6c 6f 67 5e 2e 70 49 74 | 65 6d 50 72 6f 63 29 3b |log^.pIt|emProc);|
|00003c80| 0d 09 09 09 7b 20 4e 6f | 77 20 77 65 d5 6c 6c 20 |....{ No|w we.ll |
|00003c90| 74 65 6c 6c 20 74 68 65 | 20 6d 6f 64 61 6c 20 69 |tell the| modal i|
|00003ca0| 74 65 6d 20 68 61 6e 64 | 6c 65 72 20 77 68 65 72 |tem hand|ler wher|
|00003cb0| 65 20 6f 75 72 20 72 6f | 75 74 69 6e 65 20 69 73 |e our ro|utine is|
|00003cc0| 20 7d 0d 09 09 09 50 72 | 74 4a 6f 62 44 69 61 6c | }....Pr|tJobDial|
|00003cd0| 6f 67 5e 2e 70 49 74 65 | 6d 50 72 6f 63 20 3a 3d |og^.pIte|mProc :=|
|00003ce0| 20 50 72 6f 63 50 74 72 | 28 40 4d 79 4a 6f 62 49 | ProcPtr|(@MyJobI|
|00003cf0| 74 65 6d 73 29 3b 0d 09 | 09 09 7b 20 50 72 44 6c |tems);..|..{ PrDl|
|00003d00| 67 4d 61 69 6e 20 65 78 | 70 65 63 74 73 20 61 20 |gMain ex|pects a |
|00003d10| 70 6f 69 6e 74 65 72 20 | 74 6f 20 74 68 65 20 6d |pointer |to the m|
|00003d20| 6f 64 69 66 69 65 64 20 | 64 69 61 6c 6f 67 20 74 |odified |dialog t|
|00003d30| 6f 20 62 65 20 09 09 09 | 20 20 72 65 74 75 72 6e |o be ...| return|
|00003d40| 65 64 2e 2e 2e 2e 20 7d | 0d 09 09 09 4d 79 4a 6f |ed.... }|....MyJo|
|00003d50| 62 44 6c 67 49 6e 69 74 | 20 3a 3d 20 50 72 74 4a |bDlgInit| := PrtJ|
|00003d60| 6f 62 44 69 61 6c 6f 67 | 3b 0d 09 09 45 4e 44 3b |obDialog|;...END;|
|00003d70| 09 09 09 09 09 09 09 20 | 7b 6d 79 4a 6f 62 44 6c |....... |{myJobDl|
|00003d80| 67 49 6e 69 74 7d 0d 09 | 7b 2d 2d 2d 2d 2d 2d 2d |gInit}..|{-------|
|00003d90| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003da0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003db0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003dc0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00003dd0| 2d 7d 0d 09 46 55 4e 43 | 54 49 4f 4e 20 50 72 69 |-}..FUNC|TION Pri|
|00003de0| 6e 74 3a 20 4f 53 45 72 | 72 3b 0d 09 09 56 41 52 |nt: OSEr|r;...VAR|
|00003df0| 0d 09 09 09 62 6f 6f 6c | 09 09 09 3a 20 42 4f 4f |....bool|...: BOO|
|00003e00| 4c 45 41 4e 3b 0d 09 09 | 42 45 47 49 4e 20 09 09 |LEAN;...|BEGIN ..|
|00003e10| 09 09 09 09 20 7b 50 72 | 69 6e 74 7d 0d 09 09 09 |.... {Pr|int}....|
|00003e20| 68 50 72 69 6e 74 52 65 | 63 20 3a 3d 20 54 48 50 |hPrintRe|c := THP|
|00003e30| 72 69 6e 74 28 4e 65 77 | 48 61 6e 64 6c 65 28 73 |rint(New|Handle(s|
|00003e40| 69 7a 65 6f 66 28 54 50 | 72 69 6e 74 29 29 29 3b |izeof(TP|rint)));|
|00003e50| 0d 09 09 09 50 72 69 6e | 74 44 65 66 61 75 6c 74 |....Prin|tDefault|
|00003e60| 28 68 50 72 69 6e 74 52 | 65 63 29 3b 0d 09 09 09 |(hPrintR|ec);....|
|00003e70| 62 6f 6f 6c 20 3a 3d 20 | 50 72 56 61 6c 69 64 61 |bool := |PrValida|
|00003e80| 74 65 28 68 50 72 69 6e | 74 52 65 63 29 3b 0d 09 |te(hPrin|tRec);..|
|00003e90| 09 09 49 46 20 28 50 72 | 45 72 72 6f 72 20 3c 3e |..IF (Pr|Error <>|
|00003ea0| 20 6e 6f 45 72 72 29 20 | 54 48 45 4e 20 42 45 47 | noErr) |THEN BEG|
|00003eb0| 49 4e 0d 09 09 09 09 50 | 72 69 6e 74 20 3a 3d 20 |IN.....P|rint := |
|00003ec0| 50 72 45 72 72 6f 72 3b | 0d 09 09 09 09 45 78 69 |PrError;|.....Exi|
|00003ed0| 74 28 50 72 69 6e 74 29 | 3b 0d 09 09 09 45 4e 44 |t(Print)|;....END|
|00003ee0| 3b 09 09 09 09 09 09 20 | 7b 49 66 7d 0d 09 09 09 |;...... |{If}....|
|00003ef0| 7b 20 63 61 6c 6c 20 50 | 72 4a 6f 62 49 6e 69 74 |{ call P|rJobInit|
|00003f00| 20 74 6f 20 67 65 74 20 | 70 6f 69 6e 74 65 72 20 | to get |pointer |
|00003f10| 74 6f 20 74 68 65 20 69 | 6e 76 69 73 69 62 6c 65 |to the i|nvisible|
|00003f20| 20 6a 6f 62 20 64 69 61 | 6c 6f 67 20 7d 0d 09 09 | job dia|log }...|
|00003f30| 09 50 72 74 4a 6f 62 44 | 69 61 6c 6f 67 20 3a 3d |.PrtJobD|ialog :=|
|00003f40| 20 50 72 4a 6f 62 49 6e | 69 74 28 68 50 72 69 6e | PrJobIn|it(hPrin|
|00003f50| 74 52 65 63 29 3b 0d 09 | 09 09 49 46 20 28 50 72 |tRec);..|..IF (Pr|
|00003f60| 45 72 72 6f 72 20 3c 3e | 20 6e 6f 45 72 72 29 20 |Error <>| noErr) |
|00003f70| 54 48 45 4e 20 42 45 47 | 49 4e 0d 09 09 09 09 50 |THEN BEG|IN.....P|
|00003f80| 72 69 6e 74 20 3a 3d 20 | 50 72 45 72 72 6f 72 3b |rint := |PrError;|
|00003f90| 0d 09 09 09 09 45 78 69 | 74 28 50 72 69 6e 74 29 |.....Exi|t(Print)|
|00003fa0| 3b 0d 09 09 09 45 4e 44 | 3b 09 09 09 09 09 09 20 |;....END|;...... |
|00003fb0| 7b 49 66 7d 0d 20 7b 48 | 65 72 65 d5 73 20 74 68 |{If}. {H|ere.s th|
|00003fc0| 65 20 6c 69 6e 65 20 74 | 68 61 74 20 64 6f 65 73 |e line t|hat does|
|00003fd0| 20 69 74 20 61 6c 6c 21 | 7d 0d 09 09 09 49 46 20 | it all!|}....IF |
|00003fe0| 4e 4f 54 20 28 50 72 44 | 6c 67 4d 61 69 6e 28 68 |NOT (PrD|lgMain(h|
|00003ff0| 50 72 69 6e 74 52 65 63 | 2c 40 4d 79 4a 6f 62 44 |PrintRec|,@MyJobD|
|00004000| 6c 67 49 6e 69 74 29 29 | 20 54 48 45 4e 20 42 45 |lgInit))| THEN BE|
|00004010| 47 49 4e 0d 09 09 09 09 | 50 72 69 6e 74 20 3a 3d |GIN.....|Print :=|
|00004020| 20 63 61 6e 63 65 6c 3b | 0d 09 09 09 09 45 78 69 | cancel;|.....Exi|
|00004030| 74 28 50 72 69 6e 74 29 | 3b 0d 09 09 09 45 4e 44 |t(Print)|;....END|
|00004040| 3b 09 09 09 09 09 09 20 | 7b 49 66 7d 0d 09 09 09 |;...... |{If}....|
|00004050| 49 46 20 50 72 45 72 72 | 6f 72 20 3c 3e 20 6e 6f |IF PrErr|or <> no|
|00004060| 45 72 72 20 54 48 45 4e | 20 50 72 69 6e 74 20 3a |Err THEN| Print :|
|00004070| 3d 20 50 72 45 72 72 6f | 72 3b 0d 09 09 09 7b 20 |= PrErro|r;....{ |
|00004080| 74 68 61 74 d5 73 20 61 | 6c 6c 20 66 6f 72 20 6e |that.s a|ll for n|
|00004090| 6f 77 20 7d 0d 09 09 45 | 4e 44 3b 09 09 09 09 09 |ow }...E|ND;.....|
|000040a0| 09 09 20 7b 20 50 72 69 | 6e 74 20 7d 0d 09 7b 2d |.. { Pri|nt }..{-|
|000040b0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000040c0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000040d0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000040e0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000040f0| 2d 2d 2d 2d 2d 2d 2d 7d | 0d 09 42 45 47 49 4e 20 |-------}|..BEGIN |
|00004100| 09 09 09 09 09 09 09 20 | 7b 50 52 4f 47 52 41 4d |....... |{PROGRAM|
|00004110| 7d 0d 09 09 55 6e 6c 6f | 61 64 53 65 67 28 40 5f |}...Unlo|adSeg(@_|
|00004120| 44 61 74 61 49 6e 69 74 | 29 3b 09 20 7b 72 65 6d |DataInit|);. {rem|
|00004130| 6f 76 65 20 64 61 74 61 | 20 69 6e 69 74 69 61 6c |ove data| initial|
|00004140| 69 7a 61 74 69 6f 6e 20 | 63 6f 64 65 20 62 65 66 |ization |code bef|
|00004150| 6f 72 65 20 09 09 09 09 | 09 09 20 20 61 6e 79 20 |ore ....|.. any |
|00004160| 61 6c 6c 6f 63 61 74 69 | 6f 6e 73 7d 0d 09 09 49 |allocati|ons}...I|
|00004170| 6e 69 74 47 72 61 66 28 | 40 74 68 65 50 6f 72 74 |nitGraf(|@thePort|
|00004180| 29 3b 0d 09 09 49 6e 69 | 74 46 6f 6e 74 73 3b 0d |);...Ini|tFonts;.|
|00004190| 09 09 46 6c 75 73 68 45 | 76 65 6e 74 73 28 65 76 |..FlushE|vents(ev|
|000041a0| 65 72 79 45 76 65 6e 74 | 2c 30 29 3b 0d 09 09 49 |eryEvent|,0);...I|
|000041b0| 6e 69 74 57 69 6e 64 6f | 77 73 3b 0d 09 09 49 6e |nitWindo|ws;...In|
|000041c0| 69 74 4d 65 6e 75 73 3b | 0d 09 09 54 45 49 6e 69 |itMenus;|...TEIni|
|000041d0| 74 3b 0d 09 09 49 6e 69 | 74 44 69 61 6c 6f 67 73 |t;...Ini|tDialogs|
|000041e0| 28 4e 49 4c 29 3b 0d 09 | 09 49 6e 69 74 43 75 72 |(NIL);..|.InitCur|
|000041f0| 73 6f 72 3b 0d 09 09 7b | 20 63 61 6c 6c 20 74 68 |sor;...{| call th|
|00004200| 65 20 72 6f 75 74 69 6e | 65 20 74 68 61 74 20 64 |e routin|e that d|
|00004210| 6f 65 73 20 70 72 69 6e | 74 69 6e 67 20 7d 0d 09 |oes prin|ting }..|
|00004220| 09 46 69 72 73 74 42 6f | 78 56 61 6c 75 65 20 3a |.FirstBo|xValue :|
|00004230| 3d 20 30 3b 09 09 20 7b | 20 76 61 6c 75 65 20 6f |= 0;.. {| value o|
|00004240| 66 20 6f 75 72 20 66 69 | 72 73 74 20 61 64 64 69 |f our fi|rst addi|
|00004250| 74 69 6f 6e 61 6c 20 62 | 6f 78 20 7d 0d 09 09 53 |tional b|ox }...S|
|00004260| 65 63 6f 6e 64 42 6f 78 | 56 61 6c 75 65 20 3a 3d |econdBox|Value :=|
|00004270| 20 30 3b 20 09 20 7b 20 | 76 61 6c 75 65 20 6f 66 | 0; . { |value of|
|00004280| 20 6f 75 72 20 73 65 63 | 6f 6e 64 20 61 64 64 74 | our sec|ond addt|
|00004290| 6c 2e 20 62 6f 78 20 7d | 0d 09 09 50 72 4f 70 65 |l. box }|...PrOpe|
|000042a0| 6e 3b 20 20 20 20 7b 20 | 4f 70 65 6e 20 74 68 65 |n; { |Open the|
|000042b0| 20 50 72 69 6e 74 20 4d | 61 6e 61 67 65 72 20 7d | Print M|anager }|
|000042c0| 0d 09 09 49 46 20 50 72 | 45 72 72 6f 72 20 3d 20 |...IF Pr|Error = |
|000042d0| 6e 6f 45 72 72 20 54 48 | 45 4e 0d 09 09 09 65 72 |noErr TH|EN....er|
|000042e0| 72 20 3a 3d 20 50 72 69 | 6e 74 20 20 20 20 20 7b |r := Pri|nt {|
|000042f0| 20 54 68 69 73 20 61 63 | 74 75 61 6c 6c 79 20 62 | This ac|tually b|
|00004300| 72 69 6e 67 73 20 75 70 | 20 74 68 65 20 6d 6f 64 |rings up| the mod|
|00004310| 69 66 69 65 64 20 4a 6f | 62 20 09 09 09 09 09 20 |ified Jo|b ..... |
|00004320| 20 20 20 20 64 69 61 6c | 6f 67 20 7d 0d 09 09 45 | dial|og }...E|
|00004330| 4c 53 45 20 42 45 47 49 | 4e 0d 09 09 09 7b 74 65 |LSE BEGI|N....{te|
|00004340| 6c 6c 20 74 68 65 20 75 | 73 65 72 20 74 68 61 74 |ll the u|ser that|
|00004350| 20 50 72 4f 70 65 6e 20 | 66 61 69 6c 65 64 7d 0d | PrOpen |failed}.|
|00004360| 09 09 45 4e 44 3b 0d 09 | 09 50 72 43 6c 6f 73 65 |..END;..|.PrClose|
|00004370| 3b 20 20 20 20 7b 20 43 | 6c 6f 73 65 20 74 68 65 |; { C|lose the|
|00004380| 20 50 72 69 6e 74 20 4d | 61 6e 61 67 65 72 20 61 | Print M|anager a|
|00004390| 6e 64 20 6c 65 61 76 65 | 20 7d 0d 09 45 4e 44 2e |nd leave| }..END.|
|000043a0| 0d 54 68 65 20 4c 69 67 | 68 74 73 70 65 65 64 20 |.The Lig|htspeed |
|000043b0| 43 20 45 78 61 6d 70 6c | 65 20 50 72 6f 67 72 61 |C Exampl|e Progra|
|000043c0| 6d 0d 2f 2a 20 4e 4f 54 | 45 3a 20 41 70 70 6c 65 |m./* NOT|E: Apple|
|000043d0| 20 72 65 73 65 72 76 65 | 73 20 74 68 65 20 74 6f | reserve|s the to|
|000043e0| 70 20 68 61 6c 66 20 6f | 66 20 74 68 65 20 73 63 |p half o|f the sc|
|000043f0| 72 65 65 6e 20 28 77 68 | 65 72 65 20 74 68 65 20 |reen (wh|ere the |
|00004400| 63 75 72 72 65 6e 74 20 | 44 49 54 4c 0d 69 74 65 |current |DITL.ite|
|00004410| 6d 73 20 61 72 65 20 6c | 6f 63 61 74 65 64 29 2e |ms are l|ocated).|
|00004420| 20 41 70 70 6c 69 63 61 | 74 69 6f 6e 73 20 6d 61 | Applica|tions ma|
|00004430| 79 20 75 73 65 20 74 68 | 65 20 62 6f 74 74 6f 6d |y use th|e bottom|
|00004440| 20 68 61 6c 66 20 6f 66 | 20 74 68 65 20 73 63 72 | half of| the scr|
|00004450| 65 65 6e 20 74 6f 20 61 | 64 64 20 69 74 65 6d 73 |een to a|dd items|
|00004460| 2c 20 62 75 74 20 73 68 | 6f 75 6c 64 20 6e 6f 74 |, but sh|ould not|
|00004470| 20 63 68 61 6e 67 65 20 | 61 6e 79 20 69 74 65 6d | change |any item|
|00004480| 73 20 69 6e 20 74 68 65 | 20 74 6f 70 20 68 61 6c |s in the| top hal|
|00004490| 66 20 6f 66 20 74 68 65 | 20 73 63 72 65 65 6e 2e |f of the| screen.|
|000044a0| 20 41 6e 20 61 70 70 6c | 69 63 61 74 69 6f 6e 20 | An appl|ication |
|000044b0| 73 68 6f 75 6c 64 20 65 | 78 70 61 6e 64 20 74 68 |should e|xpand th|
|000044c0| 65 20 70 72 69 6e 74 20 | 64 69 61 6c 6f 67 73 20 |e print |dialogs |
|000044d0| 6f 6e 6c 79 20 61 73 20 | 6d 75 63 68 20 61 73 20 |only as |much as |
|000044e0| 69 73 20 61 62 73 6f 6c | 75 74 65 6c 79 20 6e 65 |is absol|utely ne|
|000044f0| 63 65 73 73 61 72 79 2e | 0d 2a 2f 0d 2f 2a 20 4e |cessary.|.*/./* N|
|00004500| 6f 74 65 3a 20 41 20 67 | 6c 6f 62 61 6c 20 73 65 |ote: A g|lobal se|
|00004510| 61 72 63 68 20 61 6e 64 | 20 72 65 70 6c 61 63 65 |arch and| replace|
|00004520| 20 6f 66 20 27 4a 6f 62 | 27 20 77 69 74 68 20 27 | of 'Job|' with '|
|00004530| 53 74 6c 27 20 77 69 6c | 6c 20 70 72 6f 64 75 63 |Stl' wil|l produc|
|00004540| 65 20 0d 09 63 6f 64 65 | 20 74 68 61 74 20 6d 6f |e ..code| that mo|
|00004550| 64 69 66 69 65 73 20 74 | 68 65 20 73 74 79 6c 65 |difies t|he style|
|00004560| 20 64 69 61 6c 6f 67 73 | 20 2a 2f 0d 23 69 6e 63 | dialogs| */.#inc|
|00004570| 6c 75 64 65 20 3c 44 69 | 61 6c 6f 67 4d 67 72 2e |lude <Di|alogMgr.|
|00004580| 68 3e 0d 23 69 6e 63 6c | 75 64 65 20 3c 4d 61 63 |h>.#incl|ude <Mac|
|00004590| 54 79 70 65 73 2e 68 3e | 0d 23 69 6e 63 6c 75 64 |Types.h>|.#includ|
|000045a0| 65 20 3c 51 75 69 63 6b | 64 72 61 77 2e 68 3e 0d |e <Quick|draw.h>.|
|000045b0| 23 69 6e 63 6c 75 64 65 | 20 3c 52 65 73 6f 75 72 |#include| <Resour|
|000045c0| 63 65 4d 67 72 2e 68 3e | 0d 23 69 6e 63 6c 75 64 |ceMgr.h>|.#includ|
|000045d0| 65 20 3c 57 69 6e 64 6f | 77 4d 67 72 2e 68 3e 0d |e <Windo|wMgr.h>.|
|000045e0| 23 69 6e 63 6c 75 64 65 | 20 3c 70 61 73 63 61 6c |#include| <pascal|
|000045f0| 2e 68 3e 0d 23 69 6e 63 | 6c 75 64 65 20 3c 70 72 |.h>.#inc|lude <pr|
|00004600| 69 6e 74 6d 67 72 2e 68 | 3e 0d 23 64 65 66 69 6e |intmgr.h|>.#defin|
|00004610| 65 20 6e 69 6c 20 30 4c | 0d 73 74 61 74 69 63 20 |e nil 0L|.static |
|00004620| 54 50 50 72 44 6c 67 20 | 50 72 74 4a 6f 62 44 69 |TPPrDlg |PrtJobDi|
|00004630| 61 6c 6f 67 3b 09 09 2f | 2a 20 70 6f 69 6e 74 65 |alog;../|* pointe|
|00004640| 72 20 74 6f 20 6a 6f 62 | 20 64 69 61 6c 6f 67 20 |r to job| dialog |
|00004650| 2a 2f 0d 2f 2a 09 54 68 | 69 73 20 70 6f 69 6e 74 |*/./*.Th|is point|
|00004660| 73 20 74 6f 20 74 68 65 | 20 66 6f 6c 6c 6f 77 69 |s to the| followi|
|00004670| 6e 67 20 73 74 72 75 63 | 74 75 72 65 3a 0d 09 0d |ng struc|ture:...|
|00004680| 09 20 20 73 74 72 75 63 | 74 20 7b 20 0d 09 09 20 |. struc|t { ... |
|00004690| 20 44 69 61 6c 6f 67 52 | 65 63 6f 72 64 09 44 6c | DialogR|ecord.Dl|
|000046a0| 67 3b 09 20 20 09 28 54 | 68 65 20 44 69 61 6c 6f |g;. .(T|he Dialo|
|000046b0| 67 20 77 69 6e 64 6f 77 | 29 0d 09 09 20 20 50 72 |g window|)... Pr|
|000046c0| 6f 63 50 74 72 09 09 70 | 46 6c 74 72 50 72 6f 63 |ocPtr..p|FltrProc|
|000046d0| 3b 09 28 54 68 65 20 46 | 69 6c 74 65 72 20 50 72 |;.(The F|ilter Pr|
|000046e0| 6f 63 2e 29 0d 09 09 20 | 20 50 72 6f 63 50 74 72 |oc.)... | ProcPtr|
|000046f0| 09 09 70 49 74 65 6d 50 | 72 6f 63 3b 09 28 54 68 |..pItemP|roc;.(Th|
|00004700| 65 20 49 74 65 6d 20 65 | 76 61 6c 75 61 74 69 6e |e Item e|valuatin|
|00004710| 67 20 70 72 6f 63 2e 20 | 2d 2d 20 09 09 09 09 09 |g proc. |-- .....|
|00004720| 09 09 77 65 27 6c 6c 20 | 63 68 61 6e 67 65 20 74 |..we'll |change t|
|00004730| 68 69 73 29 0d 09 09 20 | 20 54 48 50 72 69 6e 74 |his)... | THPrint|
|00004740| 09 09 68 50 72 69 6e 74 | 55 73 72 3b 09 28 54 68 |..hPrint|Usr;.(Th|
|00004750| 65 20 75 73 65 72 27 73 | 20 70 72 69 6e 74 20 72 |e user's| print r|
|00004760| 65 63 6f 72 64 2e 29 0d | 09 09 20 20 42 6f 6f 6c |ecord.).|.. Bool|
|00004770| 65 61 6e 09 09 66 44 6f | 49 74 3b 09 0d 09 09 20 |ean..fDo|It;.... |
|00004780| 20 42 6f 6f 6c 65 61 6e | 09 09 66 44 6f 6e 65 3b | Boolean|..fDone;|
|00004790| 09 0d 09 09 20 20 09 28 | 46 6f 75 72 20 6c 6f 6e |.... .(|Four lon|
|000047a0| 67 73 20 2d 2d 20 72 65 | 73 65 72 76 65 64 20 62 |gs -- re|served b|
|000047b0| 79 20 41 70 70 6c 65 20 | 43 6f 6d 70 75 74 65 72 |y Apple |Computer|
|000047c0| 29 0d 09 09 20 20 6c 6f | 6e 67 09 09 09 6c 55 73 |)... lo|ng...lUs|
|000047d0| 65 72 31 3b 09 09 20 0d | 09 09 20 20 6c 6f 6e 67 |er1;.. .|.. long|
|000047e0| 09 09 09 6c 55 73 65 72 | 32 3b 09 09 0d 09 09 20 |...lUser|2;..... |
|000047f0| 20 6c 6f 6e 67 09 09 09 | 6c 55 73 65 72 33 3b 09 | long...|lUser3;.|
|00004800| 0d 09 09 20 20 6c 6f 6e | 67 09 09 09 6c 55 73 65 |... lon|g...lUse|
|00004810| 72 34 3b 09 09 0d 20 20 | 20 7d 20 54 50 72 44 6c |r4;... | } TPrDl|
|00004820| 67 3b 20 2a 54 50 50 72 | 44 6c 67 3b 20 20 09 09 |g; *TPPr|Dlg; ..|
|00004830| 0d 2a 2f 0d 2f 2a 09 44 | 65 63 6c 61 72 65 20 d4 |.*/./*.D|eclare .|
|00004840| 70 61 73 63 61 6c d5 20 | 66 75 6e 63 74 69 6f 6e |pascal. |function|
|00004850| 73 20 61 6e 64 20 70 72 | 6f 63 65 64 75 72 65 73 |s and pr|ocedures|
|00004860| 20 2a 2f 0d 70 61 73 63 | 61 6c 20 42 6f 6f 6c 65 | */.pasc|al Boole|
|00004870| 61 6e 20 50 72 44 6c 67 | 4d 61 69 6e 28 29 3b 09 |an PrDlg|Main();.|
|00004880| 09 2f 2a 20 50 72 69 6e | 74 20 6d 61 6e 61 67 65 |./* Prin|t manage|
|00004890| 72 d5 73 20 64 69 61 6c | 6f 67 20 68 61 6e 64 6c |r.s dial|og handl|
|000048a0| 65 72 20 2a 2f 0d 70 61 | 73 63 61 6c 20 54 50 50 |er */.pa|scal TPP|
|000048b0| 72 44 6c 67 20 50 72 4a | 6f 62 49 6e 69 74 28 29 |rDlg PrJ|obInit()|
|000048c0| 3b 09 09 2f 2a 20 47 65 | 74 73 20 73 74 61 6e 64 |;../* Ge|ts stand|
|000048d0| 61 72 64 20 70 72 69 6e | 74 20 6a 6f 62 20 64 69 |ard prin|t job di|
|000048e0| 61 6c 6f 67 2e 20 2a 2f | 0d 70 61 73 63 61 6c 20 |alog. */|.pascal |
|000048f0| 54 50 50 72 44 6c 67 20 | 4d 79 4a 6f 62 44 6c 67 |TPPrDlg |MyJobDlg|
|00004900| 49 6e 69 74 28 29 3b 09 | 2f 2a 20 4f 75 72 20 65 |Init();.|/* Our e|
|00004910| 78 74 65 6e 74 69 6f 6e | 20 74 6f 20 50 72 4a 6f |xtention| to PrJo|
|00004920| 62 49 6e 69 74 20 2a 2f | 0d 70 61 73 63 61 6c 20 |bInit */|.pascal |
|00004930| 76 6f 69 64 20 4d 79 4a | 6f 62 49 74 65 6d 73 28 |void MyJ|obItems(|
|00004940| 29 3b 09 09 2f 2a 20 4f | 75 72 20 6d 6f 64 61 6c |);../* O|ur modal|
|00004950| 20 69 74 65 6d 20 68 61 | 6e 64 6c 65 72 20 2a 2f | item ha|ndler */|
|00004960| 0d 23 64 65 66 69 6e 65 | 20 4d 79 44 49 54 4c 20 |.#define| MyDITL |
|00004970| 32 35 36 09 09 09 2f 2a | 20 72 65 73 6f 75 72 63 |256.../*| resourc|
|00004980| 65 20 49 44 20 6f 66 20 | 6d 79 20 44 49 54 4c 20 |e ID of |my DITL |
|00004990| 74 6f 20 62 65 20 73 70 | 6c 69 63 65 64 0d 09 09 |to be sp|liced...|
|000049a0| 09 09 09 09 09 6f 6e 20 | 74 6f 20 6a 6f 62 20 64 |.....on |to job d|
|000049b0| 69 61 6c 6f 67 20 2a 2f | 0d 54 48 50 72 69 6e 74 |ialog */|.THPrint|
|000049c0| 20 68 50 72 69 6e 74 52 | 65 63 3b 09 09 09 2f 2a | hPrintR|ec;.../*|
|000049d0| 20 68 61 6e 64 6c 65 20 | 74 6f 20 70 72 69 6e 74 | handle |to print|
|000049e0| 20 72 65 63 6f 72 64 20 | 2a 2f 0d 73 68 6f 72 74 | record |*/.short|
|000049f0| 20 46 69 72 73 74 42 6f | 78 56 61 6c 75 65 20 3d | FirstBo|xValue =|
|00004a00| 20 30 3b 09 09 2f 2a 20 | 76 61 6c 75 65 20 6f 66 | 0;../* |value of|
|00004a10| 20 6f 75 72 20 66 69 72 | 73 74 20 61 64 64 69 74 | our fir|st addit|
|00004a20| 69 6f 6e 61 6c 20 62 6f | 78 20 2a 2f 0d 73 68 6f |ional bo|x */.sho|
|00004a30| 72 74 20 53 65 63 6f 6e | 64 42 6f 78 56 61 6c 75 |rt Secon|dBoxValu|
|00004a40| 65 20 3d 20 30 3b 09 09 | 2f 2a 20 76 61 6c 75 65 |e = 0;..|/* value|
|00004a50| 20 6f 66 20 6f 75 72 20 | 73 65 63 6f 6e 64 20 61 | of our |second a|
|00004a60| 64 64 74 6c 2e 20 62 6f | 78 20 2a 2f 0d 6c 6f 6e |ddtl. bo|x */.lon|
|00004a70| 67 20 70 72 46 69 72 73 | 74 49 74 65 6d 3b 09 09 |g prFirs|tItem;..|
|00004a80| 09 09 2f 2a 20 73 61 76 | 65 20 6f 75 72 20 66 69 |../* sav|e our fi|
|00004a90| 72 73 74 20 69 74 65 6d | 20 68 65 72 65 20 2a 2f |rst item| here */|
|00004aa0| 0d 6c 6f 6e 67 20 70 72 | 50 49 74 65 6d 50 72 6f |.long pr|PItemPro|
|00004ab0| 63 3b 09 09 09 2f 2a 20 | 77 65 20 6e 65 65 64 20 |c;.../* |we need |
|00004ac0| 74 6f 20 73 74 6f 72 65 | 20 74 68 65 20 6f 6c 64 |to store| the old|
|00004ad0| 20 69 74 65 6d 50 72 6f | 63 20 68 65 72 65 20 2a | itemPro|c here *|
|00004ae0| 2f 0d 2f 2a 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |/./*----|--------|
|00004af0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004b00| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004b10| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004b20| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2a 2f 0d 09 57 |--------|---*/..W|
|00004b30| 69 6e 64 6f 77 50 74 72 | 20 09 4d 79 57 69 6e 64 |indowPtr| .MyWind|
|00004b40| 6f 77 3b 0d 09 4f 53 45 | 72 72 20 09 65 72 72 3b |ow;..OSE|rr .err;|
|00004b50| 0d 09 53 74 72 32 35 35 | 20 09 6d 79 53 74 72 3b |..Str255| .myStr;|
|00004b60| 0d 6d 61 69 6e 28 29 0d | 7b 09 0d 09 52 65 63 74 |.main().|{...Rect|
|00004b70| 20 09 09 6d 79 57 52 65 | 63 74 3b 0d 09 0d 09 49 | ..myWRe|ct;....I|
|00004b80| 6e 69 74 47 72 61 66 28 | 26 74 68 65 50 6f 72 74 |nitGraf(|&thePort|
|00004b90| 29 3b 0d 09 49 6e 69 74 | 46 6f 6e 74 73 28 29 3b |);..Init|Fonts();|
|00004ba0| 0d 09 49 6e 69 74 57 69 | 6e 64 6f 77 73 28 29 3b |..InitWi|ndows();|
|00004bb0| 0d 09 49 6e 69 74 4d 65 | 6e 75 73 28 29 3b 0d 09 |..InitMe|nus();..|
|00004bc0| 49 6e 69 74 44 69 61 6c | 6f 67 73 28 6e 69 6c 29 |InitDial|ogs(nil)|
|00004bd0| 3b 0d 09 49 6e 69 74 43 | 75 72 73 6f 72 28 29 3b |;..InitC|ursor();|
|00004be0| 0d 20 20 20 09 53 65 74 | 52 65 63 74 28 26 6d 79 |. .Set|Rect(&my|
|00004bf0| 57 52 65 63 74 2c 35 30 | 2c 32 36 30 2c 33 35 30 |WRect,50|,260,350|
|00004c00| 2c 33 34 30 29 3b 0d 09 | 0d 09 2f 2a 20 63 61 6c |,340);..|../* cal|
|00004c10| 6c 20 74 68 65 20 72 6f | 75 74 69 6e 65 20 74 68 |l the ro|utine th|
|00004c20| 61 74 20 64 6f 65 73 20 | 70 72 69 6e 74 69 6e 67 |at does |printing|
|00004c30| 20 2a 2f 0d 09 50 72 4f | 70 65 6e 28 29 3b 0d 09 | */..PrO|pen();..|
|00004c40| 65 72 72 20 3d 20 50 72 | 69 6e 74 28 29 3b 0d 09 |err = Pr|int();..|
|00004c50| 0d 09 50 72 43 6c 6f 73 | 65 28 29 3b 0d 7d 20 2f |..PrClos|e();.} /|
|00004c60| 2a 20 6d 61 69 6e 20 2a | 2f 0d 2f 2a 2d 2d 2d 2d |* main *|/./*----|
|00004c70| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004c80| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004c90| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004ca0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004cb0| 2d 2d 2d 2d 2a 2f 0d 4f | 53 45 72 72 20 50 72 69 |----*/.O|SErr Pri|
|00004cc0| 6e 74 28 29 0d 7b 0d 09 | 2f 2a 20 63 61 6c 6c 20 |nt().{..|/* call |
|00004cd0| 50 72 4a 6f 62 49 6e 69 | 74 20 74 6f 20 67 65 74 |PrJobIni|t to get|
|00004ce0| 20 70 6f 69 6e 74 65 72 | 20 74 6f 20 74 68 65 20 | pointer| to the |
|00004cf0| 69 6e 76 69 73 69 62 6c | 65 20 6a 6f 62 20 64 69 |invisibl|e job di|
|00004d00| 61 6c 6f 67 20 2a 2f 0d | 09 68 50 72 69 6e 74 52 |alog */.|.hPrintR|
|00004d10| 65 63 20 3d 20 28 54 48 | 50 72 69 6e 74 29 28 4e |ec = (TH|Print)(N|
|00004d20| 65 77 48 61 6e 64 6c 65 | 28 73 69 7a 65 6f 66 28 |ewHandle|(sizeof(|
|00004d30| 54 50 72 69 6e 74 29 29 | 29 3b 0d 09 50 72 69 6e |TPrint))|);..Prin|
|00004d40| 74 44 65 66 61 75 6c 74 | 28 68 50 72 69 6e 74 52 |tDefault|(hPrintR|
|00004d50| 65 63 29 3b 0d 09 50 72 | 56 61 6c 69 64 61 74 65 |ec);..Pr|Validate|
|00004d60| 28 68 50 72 69 6e 74 52 | 65 63 29 3b 0d 09 69 66 |(hPrintR|ec);..if|
|00004d70| 20 28 50 72 45 72 72 6f | 72 28 29 20 21 3d 20 6e | (PrErro|r() != n|
|00004d80| 6f 45 72 72 29 0d 09 09 | 72 65 74 75 72 6e 20 50 |oErr)...|return P|
|00004d90| 72 45 72 72 6f 72 28 29 | 3b 09 09 0d 09 50 72 74 |rError()|;....Prt|
|00004da0| 4a 6f 62 44 69 61 6c 6f | 67 20 3d 20 50 72 4a 6f |JobDialo|g = PrJo|
|00004db0| 62 49 6e 69 74 28 68 50 | 72 69 6e 74 52 65 63 29 |bInit(hP|rintRec)|
|00004dc0| 3b 0d 09 69 66 20 28 50 | 72 45 72 72 6f 72 28 29 |;..if (P|rError()|
|00004dd0| 20 21 3d 20 6e 6f 45 72 | 72 29 0d 09 09 72 65 74 | != noEr|r)...ret|
|00004de0| 75 72 6e 20 50 72 45 72 | 72 6f 72 28 29 3b 09 09 |urn PrEr|ror();..|
|00004df0| 0d 09 0d 09 69 66 20 28 | 21 50 72 44 6c 67 4d 61 |....if (|!PrDlgMa|
|00004e00| 69 6e 28 68 50 72 69 6e | 74 52 65 63 2c 20 26 4d |in(hPrin|tRec, &M|
|00004e10| 79 4a 6f 62 44 6c 67 49 | 6e 69 74 29 29 09 2f 2a |yJobDlgI|nit))./*|
|00004e20| 20 74 68 69 73 20 6c 69 | 6e 65 20 64 6f 65 73 20 | this li|ne does |
|00004e30| 61 6c 6c 20 74 68 65 20 | 73 74 75 66 66 20 2a 2f |all the |stuff */|
|00004e40| 0d 09 09 72 65 74 75 72 | 6e 20 43 61 6e 63 65 6c |...retur|n Cancel|
|00004e50| 3b 0d 09 69 66 20 28 50 | 72 45 72 72 6f 72 28 29 |;..if (P|rError()|
|00004e60| 20 21 3d 20 6e 6f 45 72 | 72 29 0d 09 09 72 65 74 | != noEr|r)...ret|
|00004e70| 75 72 6e 20 50 72 45 72 | 72 6f 72 28 29 3b 09 09 |urn PrEr|ror();..|
|00004e80| 0d 09 0d 2f 2a 20 74 68 | 61 74 27 73 20 61 6c 6c |.../* th|at's all|
|00004e90| 20 66 6f 72 20 6e 6f 77 | 20 2a 2f 0d 09 09 0d 7d | for now| */....}|
|00004ea0| 20 2f 2a 20 50 72 69 6e | 74 20 2a 2f 0d 2f 2a 2d | /* Prin|t */./*-|
|00004eb0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004ec0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004ed0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004ee0| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00004ef0| 2d 2d 2d 2d 2d 2d 2d 2a | 2f 0d 70 61 73 63 61 6c |-------*|/.pascal|
|00004f00| 20 54 50 50 72 44 6c 67 | 20 4d 79 4a 6f 62 44 6c | TPPrDlg| MyJobDl|
|00004f10| 67 49 6e 69 74 20 28 68 | 50 72 69 6e 74 29 0d 54 |gInit (h|Print).T|
|00004f20| 48 50 72 69 6e 74 20 68 | 50 72 69 6e 74 3b 0d 2f |HPrint h|Print;./|
|00004f30| 2a 20 74 68 69 73 20 72 | 6f 75 74 69 6e 65 20 61 |* this r|outine a|
|00004f40| 70 70 65 6e 64 73 20 69 | 74 65 6d 73 20 74 6f 20 |ppends i|tems to |
|00004f50| 74 68 65 20 73 74 61 6e | 64 61 72 64 20 6a 6f 62 |the stan|dard job|
|00004f60| 20 64 69 61 6c 6f 67 20 | 61 6e 64 20 73 65 74 73 | dialog |and sets|
|00004f70| 20 75 70 20 74 68 65 0d | 09 75 73 65 72 20 66 69 | up the.|.user fi|
|00004f80| 65 6c 64 73 20 6f 66 20 | 74 68 65 20 70 72 69 6e |elds of |the prin|
|00004f90| 74 69 6e 67 20 64 69 61 | 6c 6f 67 20 72 65 63 6f |ting dia|log reco|
|00004fa0| 72 64 20 54 50 52 44 6c | 67 20 0d 09 54 68 69 73 |rd TPRDl|g ..This|
|00004fb0| 20 72 6f 75 74 69 6e 65 | 20 77 69 6c 6c 20 62 65 | routine| will be|
|00004fc0| 20 63 61 6c 6c 65 64 20 | 62 79 20 50 72 44 6c 67 | called |by PrDlg|
|00004fd0| 4d 61 69 6e 20 2a 2f 0d | 7b 0d 09 73 68 6f 72 74 |Main */.|{..short|
|00004fe0| 09 09 66 69 72 73 74 49 | 74 65 6d 3b 09 09 2f 2a |..firstI|tem;../*|
|00004ff0| 20 66 69 72 73 74 20 6e | 65 77 20 69 74 65 6d 20 | first n|ew item |
|00005000| 6e 75 6d 62 65 72 20 2a | 2f 0d 09 0d 09 73 68 6f |number *|/....sho|
|00005010| 72 74 09 09 69 74 65 6d | 54 79 70 65 3b 09 09 2f |rt..item|Type;../|
|00005020| 2a 20 6e 65 65 64 65 64 | 20 66 6f 72 20 47 65 74 |* needed| for Get|
|00005030| 44 49 74 65 6d 2f 53 65 | 74 44 49 74 65 6d 20 63 |DItem/Se|tDItem c|
|00005040| 61 6c 6c 20 2a 2f 0d 09 | 48 61 6e 64 6c 65 09 69 |all */..|Handle.i|
|00005050| 74 65 6d 48 3b 0d 09 52 | 65 63 74 09 09 69 74 65 |temH;..R|ect..ite|
|00005060| 6d 42 6f 78 3b 0d 09 0d | 09 66 69 72 73 74 49 74 |mBox;...|.firstIt|
|00005070| 65 6d 20 3d 20 41 70 70 | 65 6e 64 44 49 54 4c 20 |em = App|endDITL |
|00005080| 28 50 72 74 4a 6f 62 44 | 69 61 6c 6f 67 2c 20 4d |(PrtJobD|ialog, M|
|00005090| 79 44 49 54 4c 29 3b 20 | 2f 2a 63 61 6c 6c 20 72 |yDITL); |/*call r|
|000050a0| 6f 75 74 69 6e 65 20 74 | 6f 20 64 6f 20 09 09 09 |outine t|o do ...|
|000050b0| 09 09 09 09 09 09 74 68 | 69 73 20 2a 2f 0d 09 0d |......th|is */...|
|000050c0| 09 70 72 46 69 72 73 74 | 49 74 65 6d 20 3d 20 66 |.prFirst|Item = f|
|000050d0| 69 72 73 74 49 74 65 6d | 3b 20 2f 2a 20 73 61 76 |irstItem|; /* sav|
|000050e0| 65 20 74 68 69 73 20 73 | 6f 20 4d 79 4a 6f 62 49 |e this s|o MyJobI|
|000050f0| 74 65 6d 73 20 63 61 6e | 20 66 69 6e 64 20 69 74 |tems can| find it|
|00005100| 20 2a 2f 0d 09 0d 2f 2a | 20 6e 6f 77 20 77 65 27 | */.../*| now we'|
|00005110| 6c 6c 20 73 65 74 20 75 | 70 20 6f 75 72 20 44 49 |ll set u|p our DI|
|00005120| 54 4c 20 69 74 65 6d 73 | 20 2d 2d 20 54 68 65 20 |TL items| -- The |
|00005130| 22 46 69 72 73 74 20 42 | 6f 78 22 20 2a 2f 0d 09 |"First B|ox" */..|
|00005140| 47 65 74 44 49 74 65 6d | 28 50 72 74 4a 6f 62 44 |GetDItem|(PrtJobD|
|00005150| 69 61 6c 6f 67 2c 66 69 | 72 73 74 49 74 65 6d 2c |ialog,fi|rstItem,|
|00005160| 26 69 74 65 6d 54 79 70 | 65 2c 26 69 74 65 6d 48 |&itemTyp|e,&itemH|
|00005170| 2c 26 69 74 65 6d 42 6f | 78 29 3b 0d 09 53 65 74 |,&itemBo|x);..Set|
|00005180| 43 74 6c 56 61 6c 75 65 | 28 69 74 65 6d 48 2c 46 |CtlValue|(itemH,F|
|00005190| 69 72 73 74 42 6f 78 56 | 61 6c 75 65 29 3b 0d 09 |irstBoxV|alue);..|
|000051a0| 0d 2f 2a 20 6e 6f 77 20 | 77 65 27 6c 6c 20 73 65 |./* now |we'll se|
|000051b0| 74 20 75 70 20 74 68 65 | 20 73 65 63 6f 6e 64 20 |t up the| second |
|000051c0| 6f 66 20 6f 75 72 20 44 | 49 54 4c 20 69 74 65 6d |of our D|ITL item|
|000051d0| 73 20 20 2d 2d 20 54 68 | 65 20 22 53 65 63 6f 6e |s -- Th|e "Secon|
|000051e0| 64 20 42 6f 78 22 20 2a | 2f 0d 09 47 65 74 44 49 |d Box" *|/..GetDI|
|000051f0| 74 65 6d 28 50 72 74 4a | 6f 62 44 69 61 6c 6f 67 |tem(PrtJ|obDialog|
|00005200| 2c 66 69 72 73 74 49 74 | 65 6d 2b 31 2c 26 69 74 |,firstIt|em+1,&it|
|00005210| 65 6d 54 79 70 65 2c 26 | 69 74 65 6d 48 2c 26 69 |emType,&|itemH,&i|
|00005220| 74 65 6d 42 6f 78 29 3b | 0d 09 53 65 74 43 74 6c |temBox);|..SetCtl|
|00005230| 56 61 6c 75 65 28 69 74 | 65 6d 48 2c 53 65 63 6f |Value(it|emH,Seco|
|00005240| 6e 64 42 6f 78 56 61 6c | 75 65 29 3b 0d 09 0d 2f |ndBoxVal|ue);.../|
|00005250| 2a 20 4e 6f 77 20 63 6f | 6d 65 73 20 74 68 65 20 |* Now co|mes the |
|00005260| 70 61 72 74 20 77 68 65 | 72 65 20 77 65 20 70 61 |part whe|re we pa|
|00005270| 74 63 68 20 69 6e 20 6f | 75 72 20 69 74 65 6d 20 |tch in o|ur item |
|00005280| 68 61 6e 64 6c 65 72 2e | 20 20 57 65 20 68 61 76 |handler.| We hav|
|00005290| 65 20 74 6f 20 73 61 76 | 65 0d 09 74 68 65 20 6f |e to sav|e..the o|
|000052a0| 6c 64 20 69 74 65 6d 20 | 68 61 6e 64 6c 65 72 20 |ld item |handler |
|000052b0| 61 64 64 72 65 73 73 2c | 20 73 6f 20 77 65 20 63 |address,| so we c|
|000052c0| 61 6e 20 63 61 6c 6c 20 | 69 74 20 69 66 20 6f 6e |an call |it if on|
|000052d0| 65 20 6f 66 20 74 68 65 | 20 73 74 61 6e 64 61 72 |e of the| standar|
|000052e0| 64 20 69 74 65 6d 73 20 | 69 73 20 09 68 69 74 2c |d items |is .hit,|
|000052f0| 20 61 6e 64 20 70 75 74 | 20 6f 75 72 20 69 74 65 | and put| our ite|
|00005300| 6d 20 68 61 6e 64 6c 65 | 72 27 73 20 61 64 64 72 |m handle|r's addr|
|00005310| 65 73 73 20 69 6e 20 70 | 49 74 65 6d 50 72 6f 63 |ess in p|ItemProc|
|00005320| 20 66 69 65 6c 64 20 6f | 66 20 74 68 65 20 54 50 | field o|f the TP|
|00005330| 72 44 6c 67 20 73 74 72 | 75 63 74 0d 2a 2f 0d 09 |rDlg str|uct.*/..|
|00005340| 70 72 50 49 74 65 6d 50 | 72 6f 63 20 3d 20 28 6c |prPItemP|roc = (l|
|00005350| 6f 6e 67 29 50 72 74 4a | 6f 62 44 69 61 6c 6f 67 |ong)PrtJ|obDialog|
|00005360| 2d 3e 70 49 74 65 6d 50 | 72 6f 63 3b 0d 09 0d 2f |->pItemP|roc;.../|
|00005370| 2a 20 4e 6f 77 20 77 65 | 27 6c 6c 20 74 65 6c 6c |* Now we|'ll tell|
|00005380| 20 74 68 65 20 6d 6f 64 | 61 6c 20 69 74 65 6d 20 | the mod|al item |
|00005390| 68 61 6e 64 6c 65 72 20 | 77 68 65 72 65 20 6f 75 |handler |where ou|
|000053a0| 72 20 72 6f 75 74 69 6e | 65 20 69 73 20 2a 2f 0d |r routin|e is */.|
|000053b0| 09 50 72 74 4a 6f 62 44 | 69 61 6c 6f 67 2d 3e 70 |.PrtJobD|ialog->p|
|000053c0| 49 74 65 6d 50 72 6f 63 | 20 3d 20 28 50 72 6f 63 |ItemProc| = (Proc|
|000053d0| 50 74 72 29 26 4d 79 4a | 6f 62 49 74 65 6d 73 3b |Ptr)&MyJ|obItems;|
|000053e0| 0d 09 0d 2f 2a 20 50 72 | 44 6c 67 4d 61 69 6e 20 |.../* Pr|DlgMain |
|000053f0| 65 78 70 65 63 74 73 20 | 61 20 70 6f 69 6e 74 65 |expects |a pointe|
|00005400| 72 20 74 6f 20 74 68 65 | 20 6d 6f 64 69 66 69 65 |r to the| modifie|
|00005410| 64 20 64 69 61 6c 6f 67 | 20 74 6f 20 62 65 20 72 |d dialog| to be r|
|00005420| 65 74 75 72 6e 65 64 2e | 2e 2e 2e 20 2a 2f 0d 09 |eturned.|... */..|
|00005430| 72 65 74 75 72 6e 20 50 | 72 74 4a 6f 62 44 69 61 |return P|rtJobDia|
|00005440| 6c 6f 67 3b 0d 09 0d 7d | 20 2f 2a 6d 79 4a 6f 62 |log;...}| /*myJob|
|00005450| 44 6c 67 49 6e 69 74 2a | 2f 0d 2f 2a 2d 2d 2d 2d |DlgInit*|/./*----|
|00005460| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00005470| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00005480| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|00005490| 2d 2d 2d 2d 2d 2d 2d 2d | 2d 2d 2d 2d 2d 2d 2d 2d |--------|--------|
|000054a0| 2d 2d 2d 2a 2f 0d 2f 2a | 20 68 65 72 65 27 73 20 |---*/./*| here's |
|000054b0| 74 68 65 20 61 6e 61 6c | 6f 67 75 65 20 74 6f 20 |the anal|ogue to |
|000054c0| 74 68 65 20 53 46 20 64 | 69 61 6c 6f 67 20 68 6f |the SF d|ialog ho|
|000054d0| 6f 6b 20 2a 2f 0d 70 61 | 73 63 61 6c 20 76 6f 69 |ok */.pa|scal voi|
|000054e0| 64 20 4d 79 4a 6f 62 49 | 74 65 6d 73 28 74 68 65 |d MyJobI|tems(the|
|000054f0| 44 69 61 6c 6f 67 2c 69 | 74 65 6d 4e 6f 29 0d 54 |Dialog,i|temNo).T|
|00005500| 50 50 72 44 6c 67 09 74 | 68 65 44 69 61 6c 6f 67 |PPrDlg.t|heDialog|
|00005510| 3b 0d 73 68 6f 72 74 20 | 09 69 74 65 6d 4e 6f 3b |;.short |.itemNo;|
|00005520| 0d 7b 20 2f 2a 20 4d 79 | 4a 6f 62 49 74 65 6d 73 |.{ /* My|JobItems|
|00005530| 20 2a 2f 0d 09 73 68 6f | 72 74 20 09 6d 79 49 74 | */..sho|rt .myIt|
|00005540| 65 6d 3b 0d 09 73 68 6f | 72 74 20 09 66 69 72 73 |em;..sho|rt .firs|
|00005550| 74 49 74 65 6d 3b 0d 09 | 0d 09 73 68 6f 72 74 09 |tItem;..|..short.|
|00005560| 09 69 74 65 6d 54 79 70 | 65 3b 09 09 2f 2a 20 6e |.itemTyp|e;../* n|
|00005570| 65 65 64 65 64 20 66 6f | 72 20 47 65 74 44 49 74 |eeded fo|r GetDIt|
|00005580| 65 6d 2f 53 65 74 44 49 | 74 65 6d 20 63 61 6c 6c |em/SetDI|tem call|
|00005590| 20 2a 2f 0d 09 48 61 6e | 64 6c 65 09 69 74 65 6d | */..Han|dle.item|
|000055a0| 48 3b 0d 09 52 65 63 74 | 09 09 69 74 65 6d 42 6f |H;..Rect|..itemBo|
|000055b0| 78 3b 0d 09 0d 09 66 69 | 72 73 74 49 74 65 6d 20 |x;....fi|rstItem |
|000055c0| 3d 20 70 72 46 69 72 73 | 74 49 74 65 6d 3b 20 2f |= prFirs|tItem; /|
|000055d0| 2a 20 72 65 6d 65 6d 62 | 65 72 2c 20 77 65 20 73 |* rememb|er, we s|
|000055e0| 61 76 65 64 20 74 68 69 | 73 20 69 6e 20 6d 79 4a |aved thi|s in myJ|
|000055f0| 6f 62 44 6c 67 49 6e 69 | 74 20 2a 2f 0d 09 6d 79 |obDlgIni|t */..my|
|00005600| 49 74 65 6d 20 3d 20 69 | 74 65 6d 4e 6f 2d 66 69 |Item = i|temNo-fi|
|00005610| 72 73 74 49 74 65 6d 2b | 31 3b 09 2f 2a 20 22 6c |rstItem+|1;./* "l|
|00005620| 6f 63 61 6c 69 7a 65 22 | 20 63 75 72 72 65 6e 74 |ocalize"| current|
|00005630| 20 69 74 65 6d 20 4e 6f | 20 2a 2f 0d 09 69 66 20 | item No| */..if |
|00005640| 28 6d 79 49 74 65 6d 20 | 3e 20 30 29 20 09 2f 2a |(myItem |> 0) ./*|
|00005650| 20 69 66 20 6c 6f 63 61 | 6c 69 7a 65 64 20 69 74 | if loca|lized it|
|00005660| 65 6d 20 3e 20 30 2c 20 | 69 74 27 73 20 6f 6e 65 |em > 0, |it's one|
|00005670| 20 6f 66 20 6f 75 72 73 | 20 2a 2f 0d 09 7b 0d 09 | of ours| */..{..|
|00005680| 09 2f 2a 20 66 69 6e 64 | 20 6f 75 74 20 77 68 69 |./* find| out whi|
|00005690| 63 68 20 6f 66 20 6f 75 | 72 20 69 74 65 6d 73 20 |ch of ou|r items |
|000056a0| 77 61 73 20 68 69 74 20 | 2a 2f 0d 09 09 47 65 74 |was hit |*/...Get|
|000056b0| 44 49 74 65 6d 28 74 68 | 65 44 69 61 6c 6f 67 2c |DItem(th|eDialog,|
|000056c0| 69 74 65 6d 4e 6f 2c 26 | 69 74 65 6d 54 79 70 65 |itemNo,&|itemType|
|000056d0| 2c 26 69 74 65 6d 48 2c | 26 69 74 65 6d 42 6f 78 |,&itemH,|&itemBox|
|000056e0| 29 3b 0d 09 09 73 77 69 | 74 63 68 20 28 6d 79 49 |);...swi|tch (myI|
|000056f0| 74 65 6d 29 0d 09 09 7b | 0d 09 09 09 63 61 73 65 |tem)...{|....case|
|00005700| 20 31 3a 0d 09 09 09 09 | 2f 2a 20 69 6e 76 65 72 | 1:.....|/* inver|
|00005710| 74 20 76 61 6c 75 65 20 | 6f 66 20 46 69 72 73 74 |t value |of First|
|00005720| 42 6f 78 56 61 6c 75 65 | 20 61 6e 64 20 72 65 64 |BoxValue| and red|
|00005730| 72 61 77 20 69 74 20 2a | 2f 0d 09 09 09 09 46 69 |raw it *|/.....Fi|
|00005740| 72 73 74 42 6f 78 56 61 | 6c 75 65 20 5e 3d 20 31 |rstBoxVa|lue ^= 1|
|00005750| 3b 0d 09 09 09 09 53 65 | 74 43 74 6c 56 61 6c 75 |;.....Se|tCtlValu|
|00005760| 65 28 69 74 65 6d 48 2c | 46 69 72 73 74 42 6f 78 |e(itemH,|FirstBox|
|00005770| 56 61 6c 75 65 29 3b 0d | 09 09 09 09 62 72 65 61 |Value);.|....brea|
|00005780| 6b 3b 0d 09 09 09 63 61 | 73 65 20 32 3a 0d 09 09 |k;....ca|se 2:...|
|00005790| 09 09 2f 2a 20 69 6e 76 | 65 72 74 20 76 61 6c 75 |../* inv|ert valu|
|000057a0| 65 20 6f 66 20 53 65 63 | 6f 6e 64 42 6f 78 56 61 |e of Sec|ondBoxVa|
|000057b0| 6c 75 65 20 61 6e 64 20 | 72 65 64 72 61 77 20 69 |lue and |redraw i|
|000057c0| 74 20 2a 2f 0d 09 09 09 | 09 53 65 63 6f 6e 64 42 |t */....|.SecondB|
|000057d0| 6f 78 56 61 6c 75 65 20 | 5e 3d 20 31 3b 0d 09 09 |oxValue |^= 1;...|
|000057e0| 09 09 53 65 74 43 74 6c | 56 61 6c 75 65 28 69 74 |..SetCtl|Value(it|
|000057f0| 65 6d 48 2c 53 65 63 6f | 6e 64 42 6f 78 56 61 6c |emH,Seco|ndBoxVal|
|00005800| 75 65 29 3b 0d 09 09 09 | 09 62 72 65 61 6b 3b 0d |ue);....|.break;.|
|00005810| 09 09 09 64 65 66 61 75 | 6c 74 3a 20 44 65 62 75 |...defau|lt: Debu|
|00005820| 67 67 65 72 28 29 3b 20 | 2f 2a 20 4f 48 20 4f 48 |gger(); |/* OH OH|
|00005830| 20 2a 2f 09 0d 09 09 7d | 20 2f 2a 20 73 77 69 74 | */....}| /* swit|
|00005840| 63 68 20 2a 2f 0d 09 7d | 20 2f 2a 20 69 66 20 28 |ch */..}| /* if (|
|00005850| 6d 79 49 74 65 6d 20 3e | 20 30 29 20 2a 2f 0d 09 |myItem >| 0) */..|
|00005860| 65 6c 73 65 20 2f 2a 20 | 63 68 61 69 6e 20 74 6f |else /* |chain to|
|00005870| 20 73 74 61 6e 64 61 72 | 64 20 69 74 65 6d 20 68 | standar|d item h|
|00005880| 61 6e 64 6c 65 72 2c 20 | 77 68 6f 73 65 20 61 64 |andler, |whose ad|
|00005890| 64 72 65 73 73 20 69 73 | 20 73 61 76 65 64 20 69 |dress is| saved i|
|000058a0| 6e 0d 09 09 09 70 72 50 | 49 74 65 6d 50 72 6f 63 |n....prP|ItemProc|
|000058b0| 20 2a 2f 0d 09 7b 0d 09 | 09 43 61 6c 6c 50 61 73 | */..{..|.CallPas|
|000058c0| 63 61 6c 28 74 68 65 44 | 69 61 6c 6f 67 2c 69 74 |cal(theD|ialog,it|
|000058d0| 65 6d 4e 6f 2c 70 72 50 | 49 74 65 6d 50 72 6f 63 |emNo,prP|ItemProc|
|000058e0| 29 3b 0d 09 7d 0d 7d 20 | 2f 2a 20 4d 79 4a 6f 62 |);..}.} |/* MyJob|
|000058f0| 49 74 65 6d 73 20 2a 2f | 0d 54 68 65 20 52 65 7a |Items */|.The Rez|
|00005900| 20 53 6f 75 72 63 65 0d | 23 69 6e 63 6c 75 64 65 | Source.|#include|
|00005910| 20 22 74 79 70 65 73 2e | 72 22 0d 72 65 73 6f 75 | "types.|r".resou|
|00005920| 72 63 65 20 27 44 49 54 | 4c 27 20 28 32 35 36 29 |rce 'DIT|L' (256)|
|00005930| 20 7b 0d 09 7b 09 2f 2a | 20 61 72 72 61 79 20 44 | {..{./*| array D|
|00005940| 49 54 4c 61 72 72 61 79 | 3a 20 32 20 65 6c 65 6d |ITLarray|: 2 elem|
|00005950| 65 6e 74 73 20 2a 2f 0d | 09 09 2f 2a 20 5b 31 5d |ents */.|../* [1]|
|00005960| 20 2a 2f 0d 09 09 7b 38 | 2c 20 30 2c 20 32 34 2c | */...{8|, 0, 24,|
|00005970| 20 31 31 32 7d 2c 0d 09 | 09 43 68 65 63 6b 42 6f | 112},..|.CheckBo|
|00005980| 78 20 7b 0d 09 09 09 65 | 6e 61 62 6c 65 64 2c 0d |x {....e|nabled,.|
|00005990| 09 09 09 22 46 69 72 73 | 74 20 42 6f 78 22 0d 09 |..."Firs|t Box"..|
|000059a0| 09 7d 3b 0d 09 09 2f 2a | 20 5b 32 5d 20 2a 2f 0d |.};.../*| [2] */.|
|000059b0| 09 09 7b 38 2c 20 31 37 | 35 2c 20 32 34 2c 20 32 |..{8, 17|5, 24, 2|
|000059c0| 38 37 7d 2c 0d 09 09 43 | 68 65 63 6b 42 6f 78 20 |87},...C|heckBox |
|000059d0| 7b 0d 09 09 09 65 6e 61 | 62 6c 65 64 2c 0d 09 09 |{....ena|bled,...|
|000059e0| 09 22 53 65 63 6f 6e 64 | 20 42 6f 78 22 0d 09 09 |."Second| Box"...|
|000059f0| 7d 0d 09 7d 0d 7d 3b 0d | 46 75 72 74 68 65 72 20 |}..}.};.|Further |
|00005a00| 52 65 66 65 72 65 6e 63 | 65 3a 0d a5 09 54 68 65 |Referenc|e:...The|
|00005a10| 20 50 72 69 6e 74 69 6e | 67 20 4d 61 6e 61 67 65 | Printin|g Manage|
|00005a20| 72 0d a5 09 54 68 65 20 | 44 69 61 6c 6f 67 20 4d |r...The |Dialog M|
|00005a30| 61 6e 61 67 65 72 0d 15 | 28 00 00 00 00 03 48 02 |anager..|(.....H.|
|00005a40| 52 00 11 02 ff 0c 00 ff | ff ff ff 00 00 00 00 00 |R.......|........|
|00005a50| 00 00 00 02 52 00 00 03 | 48 00 00 00 00 00 00 00 |....R...|H.......|
|00005a60| a1 00 64 00 0c 57 4f 52 | 44 00 00 00 00 00 53 01 |..d..WOR|D.....S.|
|00005a70| ca 00 a0 00 8c 00 a1 00 | 64 00 0c 57 4f 52 44 00 |........|d..WORD.|
|00005a80| 00 00 00 00 52 01 c9 00 | a0 00 82 00 1e 00 01 00 |....R...|........|
|00005a90| 0a 00 2f 00 5a 00 81 02 | 23 00 07 00 00 00 00 00 |../.Z...|#.......|
|00005aa0| 08 00 0a 00 09 30 49 88 | 3a b5 9c f0 39 00 22 00 |.....0I.|:...9.".|
|00005ab0| 7b 02 1a 00 00 00 09 ff | ff ff ff ff ff ff ff 00 |{.......|........|
|00005ac0| 23 00 00 00 a0 00 c4 00 | a1 00 64 00 0a 4f 4e 4c |#.......|..d..ONL|
|00005ad0| 4e 00 66 00 00 01 fe 00 | a0 00 8c 00 a1 00 64 00 |N.f.....|......d.|
|00005ae0| 31 64 72 77 32 00 02 01 | c9 00 2d 01 e1 01 5f 00 |1drw2...|..-..._.|
|00005af0| 00 80 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005b00| 00 00 00 ff ff ff ff ff | ff 00 01 00 00 01 8f 00 |........|........|
|00005b10| 00 00 00 00 a1 00 96 00 | 0c 01 00 00 00 02 78 00 |........|......x.|
|00005b20| 00 00 00 00 00 00 a1 00 | 64 00 10 64 72 77 32 00 |........|d..drw2.|
|00005b30| 3a 00 05 00 00 00 00 00 | 01 00 00 00 a1 00 64 00 |:.......|......d.|
|00005b40| 0e 64 72 77 32 00 3a 00 | 02 00 24 00 00 00 00 00 |.drw2.:.|..$.....|
|00005b50| a1 00 64 00 34 64 72 77 | 32 00 3a 00 01 00 03 01 |..d.4drw|2.:.....|
|00005b60| 00 00 18 00 00 00 00 00 | 00 00 00 00 00 00 01 00 |........|........|
|00005b70| 01 00 01 00 01 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005b80| 00 00 00 00 00 00 00 00 | 00 00 a1 00 9a 00 08 ff |........|........|
|00005b90| fa 00 00 00 97 40 00 00 | a0 00 98 00 2c 00 08 00 |.....@..|....,...|
|00005ba0| 14 05 54 69 6d 65 73 00 | 03 00 14 00 04 01 00 00 |..Times.|........|
|00005bb0| 0d 00 18 00 2e 00 04 00 | 00 01 00 00 10 57 49 51 |........|.....WIQ|
|00005bc0| 6b 57 49 51 6b 00 2b 5d | 42 13 4e 65 77 20 54 65 |kWIQk.+]|B.New Te|
|00005bd0| 63 68 6e 69 63 61 6c 20 | 4e 6f 74 65 73 00 a0 00 |chnical |Notes...|
|00005be0| 99 00 a1 00 64 00 08 64 | 72 77 32 00 3a 00 04 00 |....d..d|rw2.:...|
|00005bf0| a1 14 e3 00 02 00 01 00 | a0 00 97 00 a1 00 64 00 |........|......d.|
|00005c00| 31 64 72 77 32 00 02 02 | 06 01 65 02 19 01 f4 00 |1drw2...|..e.....|
|00005c10| 00 80 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005c20| 00 00 00 ff ff ff ff ff | ff 00 01 00 00 01 50 00 |........|......P.|
|00005c30| 00 00 00 00 a1 00 96 00 | 0c 01 00 00 00 02 78 00 |........|......x.|
|00005c40| 00 00 00 00 00 00 a1 00 | 64 00 10 64 72 77 32 00 |........|d..drw2.|
|00005c50| 3a 00 05 00 00 00 00 00 | 01 00 00 00 a1 00 64 00 |:.......|......d.|
|00005c60| 0e 64 72 77 32 00 3a 00 | 02 00 24 00 00 00 00 00 |.drw2.:.|..$.....|
|00005c70| a1 00 64 00 34 64 72 77 | 32 00 3a 00 01 00 03 00 |..d.4drw|2.:.....|
|00005c80| 00 00 12 00 00 00 00 00 | 00 00 00 00 00 00 01 00 |........|........|
|00005c90| 01 00 01 00 01 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005ca0| 00 00 00 00 00 00 00 00 | 00 00 a1 00 9a 00 08 ff |........|........|
|00005cb0| fb 80 00 00 45 c0 00 00 | a0 00 98 00 04 00 00 00 |....E...|........|
|00005cc0| 0d 00 12 00 15 16 80 00 | 28 00 7b 01 95 11 44 65 |........|(.{...De|
|00005cd0| 76 65 6c 6f 70 65 72 20 | 53 75 70 70 6f 72 74 00 |veloper |Support.|
|00005ce0| a0 00 99 00 a1 00 64 00 | 08 64 72 77 32 00 3a 00 |......d.|.drw2.:.|
|00005cf0| 04 00 a1 14 e3 00 02 00 | 01 00 a0 00 97 00 a1 00 |........|........|
|00005d00| 64 00 60 64 72 77 32 00 | 03 02 00 00 2d 02 00 01 |d.`drw2.|....-...|
|00005d10| ef 00 00 00 00 00 00 00 | 00 02 02 00 00 00 00 00 |........|........|
|00005d20| 00 00 00 00 00 ff ff ff | ff ff ff 00 01 00 01 08 |........|........|
|00005d30| 4b 00 00 00 00 02 00 01 | ef 02 00 00 2d 00 00 00 |K.......|....-...|
|00005d40| 00 00 00 00 00 00 01 00 | 14 00 0c 00 03 00 02 00 |........|........|
|00005d50| 00 00 5a 00 01 00 00 00 | 02 00 00 00 03 00 0c 00 |..Z.....|........|
|00005d60| 00 00 00 00 07 00 02 00 | 02 00 08 00 08 00 20 00 |........|...... .|
|00005d70| 66 02 1c 00 66 00 5a 00 | a1 00 64 00 31 64 72 77 |f...f.Z.|..d.1drw|
|00005d80| 32 00 02 01 ca 01 c0 01 | fa 01 e9 00 00 00 00 00 |2.......|........|
|00005d90| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 ff |........|........|
|00005da0| ff ff ff ff ff 00 01 00 | 00 01 4b 00 00 00 00 00 |........|..K.....|
|00005db0| a1 00 96 00 0c 01 00 00 | 00 02 78 00 00 00 00 00 |........|..x.....|
|00005dc0| 00 00 a1 00 64 00 10 64 | 72 77 32 00 3a 00 05 00 |....d..d|rw2.:...|
|00005dd0| 00 00 00 00 01 00 00 00 | a1 00 64 00 0e 64 72 77 |........|..d..drw|
|00005de0| 32 00 3a 00 02 00 24 00 | 00 00 00 00 a1 00 64 00 |2.:...$.|......d.|
|00005df0| 34 64 72 77 32 00 3a 00 | 01 00 03 00 00 00 30 00 |4drw2.:.|......0.|
|00005e00| 00 00 00 00 00 00 00 00 | 00 00 01 00 01 00 01 00 |........|........|
|00005e10| 01 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005e20| 00 00 00 00 00 00 a1 00 | 9a 00 08 ff f4 00 00 00 |........|........|
|00005e30| 13 80 00 00 a0 00 98 00 | 0d 00 30 00 28 00 55 01 |........|..0.(.U.|
|00005e40| ef 01 f0 00 a0 00 99 00 | a1 00 64 00 08 64 72 77 |........|..d..drw|
|00005e50| 32 00 3a 00 04 00 a1 14 | e3 00 02 00 01 00 a0 00 |2.:.....|........|
|00005e60| 97 00 a1 00 64 00 31 64 | 72 77 32 00 02 01 ef 01 |....d.1d|rw2.....|
|00005e70| e6 01 fa 01 f0 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005e80| 00 00 00 00 00 00 00 00 | 00 ff ff ff ff ff ff 00 |........|........|
|00005e90| 01 00 00 01 00 00 00 00 | 00 00 a1 00 96 00 0c 01 |........|........|
|00005ea0| 00 00 00 02 78 00 00 00 | 00 00 00 00 a1 00 64 00 |....x...|......d.|
|00005eb0| 10 64 72 77 32 00 3a 00 | 05 00 00 00 00 00 01 00 |.drw2.:.|........|
|00005ec0| 00 00 a1 00 64 00 0e 64 | 72 77 32 00 3a 00 02 00 |....d..d|rw2.:...|
|00005ed0| 24 00 00 00 00 00 a1 00 | 64 00 34 64 72 77 32 00 |$.......|d.4drw2.|
|00005ee0| 3a 00 01 00 03 00 00 00 | 09 00 00 00 00 00 00 00 |:.......|........|
|00005ef0| 00 00 00 00 01 00 01 00 | 01 00 01 00 00 00 00 00 |........|........|
|00005f00| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005f10| a1 00 9a 00 08 ff fd 80 | 00 00 04 00 00 00 a0 00 |........|........|
|00005f20| 98 00 0d 00 09 00 15 6c | 00 00 2b 26 09 01 a8 00 |.......l|..+&....|
|00005f30| a0 00 99 00 a1 00 64 00 | 08 64 72 77 32 00 3a 00 |......d.|.drw2.:.|
|00005f40| 04 00 a1 14 e3 00 02 00 | 01 00 a0 00 97 00 a1 00 |........|........|
|00005f50| 64 00 31 64 72 77 32 00 | 02 01 e5 00 2d 01 f8 00 |d.1drw2.|....-...|
|00005f60| 79 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |y.......|........|
|00005f70| 00 00 00 00 00 ff ff ff | ff ff ff 00 01 00 01 01 |........|........|
|00005f80| 00 00 00 01 00 00 a1 00 | 96 00 0c 01 00 00 00 02 |........|........|
|00005f90| 78 00 00 00 00 00 00 00 | a1 00 64 00 10 64 72 77 |x.......|..d..drw|
|00005fa0| 32 00 3a 00 05 00 00 00 | 00 00 01 00 00 00 a1 00 |2.:.....|........|
|00005fb0| 64 00 0e 64 72 77 32 00 | 3a 00 02 00 24 00 00 00 |d..drw2.|:...$...|
|00005fc0| 00 00 a1 00 64 00 34 64 | 72 77 32 00 3a 00 01 00 |....d.4d|rw2.:...|
|00005fd0| 03 00 00 00 12 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005fe0| 01 00 01 00 01 00 01 00 | 00 00 00 00 00 00 00 00 |........|........|
|00005ff0| 00 00 00 00 00 00 00 00 | 00 00 00 00 a1 00 9a 00 |........|........|
|00006000| 08 ff fb 80 00 00 25 00 | 00 00 a0 00 98 00 0d 00 |......%.|........|
|00006010| 12 00 15 42 80 00 28 00 | 5a 00 5c 09 4d 61 63 69 |...B..(.|Z.\.Maci|
|00006020| 6e 74 6f 73 68 00 a0 00 | 99 00 a1 00 64 00 08 64 |ntosh...|....d..d|
|00006030| 72 77 32 00 3a 00 04 00 | a1 14 e3 00 02 00 01 00 |rw2.:...|........|
|00006040| a0 00 97 00 a0 00 8d 00 | a1 00 64 00 06 64 72 77 |........|..d..drw|
|00006050| 32 00 44 00 a0 00 83 00 | a1 00 64 00 04 57 4f 52 |2.D.....|..d..WOR|
|00006060| 44 00 a0 00 8d 00 01 00 | 0a 00 00 00 00 03 49 02 |D.......|......I.|
|00006070| 52 00 04 01 00 00 2e 00 | 04 00 00 00 00 00 10 00 |R.......|........|
|00006080| 01 00 01 00 01 00 01 00 | a1 00 64 00 10 4f 4e 4c |........|..d..ONL|
|00006090| 4e 00 64 00 00 00 8e 00 | 5a 00 a1 01 7d 00 28 00 |N.d.....|Z...}.(.|
|000060a0| 9c 00 5a 22 50 52 20 39 | 20 2d 20 50 72 69 6e 74 |..Z"PR 9| - Print|
|000060b0| 20 44 69 61 6c 6f 67 73 | 3a 20 41 64 64 69 6e 67 | Dialogs|: Adding|
|000060c0| 20 49 74 65 6d 73 00 00 | 0d 00 0e 00 a1 00 64 00 | Items..|......d.|
|000060d0| 10 4f 4e 4c 4e 00 64 00 | 23 00 a0 00 5a 00 af 00 |.ONLN.d.|#...Z...|
|000060e0| 91 00 2a 10 08 50 72 69 | 6e 74 69 6e 67 00 04 00 |..*..Pri|nting...|
|000060f0| 00 00 0d 00 0c 00 a1 00 | 64 00 10 4f 4e 4c 4e 00 |........|d..ONLN.|
|00006100| 64 00 2d 00 bb 00 5a 00 | c7 00 92 00 2a 18 0b 52 |d.-...Z.|....*..R|
|00006110| 65 76 69 73 65 64 20 62 | 79 3a 00 00 a1 00 64 00 |evised b|y:....d.|
|00006120| 10 4f 4e 4c 4e 00 64 00 | 3a 00 bb 01 e3 00 c7 02 |.ONLN.d.|:.......|
|00006130| 1c 00 28 00 c4 01 e3 0a | 4d 61 72 63 68 20 31 39 |..(.....|March 19|
|00006140| 38 38 00 00 a1 00 64 00 | 10 4f 4e 4c 4e 00 64 00 |88....d.|.ONLN.d.|
|00006150| 45 00 c7 00 5a 00 d3 00 | 8f 00 28 00 d0 00 5a 0b |E...Z...|..(...Z.|
|00006160| 57 72 69 74 74 65 6e 20 | 62 79 3a 00 a1 00 64 00 |Written |by:...d.|
|00006170| 10 4f 4e 4c 4e 00 64 00 | 51 00 c7 00 a2 00 d3 00 |.ONLN.d.|Q.......|
|00006180| ee 00 29 48 0f 47 69 6e | 67 65 72 20 4a 65 72 6e |..)H.Gin|ger Jern|
|00006190| 69 67 61 6e 00 00 a1 00 | 64 00 10 4f 4e 4c 4e 00 |igan....|d..ONLN.|
|000061a0| 64 00 61 00 c7 01 cf 00 | d3 02 1c 00 28 00 d0 01 |d.a.....|....(...|
|000061b0| cf 0d 4e 6f 76 65 6d 62 | 65 72 20 31 39 38 36 00 |..Novemb|er 1986.|
|000061c0| a1 00 64 00 10 4f 4e 4c | 4e 00 64 00 71 00 d3 00 |..d..ONL|N.d.q...|
|000061d0| a2 00 df 00 dc 00 28 00 | dc 00 a2 0b 4c 65 77 20 |......(.|....Lew |
|000061e0| 52 6f 6c 6c 69 6e 73 00 | a1 00 64 00 10 4f 4e 4c |Rollins.|..d..ONL|
|000061f0| 4e 00 64 00 7e 00 eb 00 | 5a 00 f7 02 0b 00 28 00 |N.d.~...|Z.....(.|
|00006200| f4 00 5a 5a 54 68 69 73 | 20 74 65 63 68 6e 69 63 |..ZZThis| technic|
|00006210| 61 6c 20 6e 6f 74 65 20 | 64 69 73 63 75 73 73 65 |al note |discusse|
|00006220| 73 20 68 6f 77 20 74 6f | 20 61 64 64 20 79 6f 75 |s how to| add you|
|00006230| 72 20 6f 77 6e 20 69 74 | 65 6d 73 20 74 6f 20 74 |r own it|ems to t|
|00006240| 68 65 20 50 72 69 6e 74 | 69 6e 67 20 4d 61 6e 61 |he Print|ing Mana|
|00006250| 67 65 72 d5 73 20 64 69 | 61 6c 6f 67 73 2e 00 00 |ger.s di|alogs...|
|00006260| 07 00 01 00 01 00 20 01 | 03 00 58 01 03 02 1d 00 |...... .|..X.....|
|00006270| a1 00 64 00 10 4f 4e 4c | 4e 00 64 00 d9 01 10 00 |..d..ONL|N.d.....|
|00006280| 5a 01 1c 01 e7 00 2a 25 | 53 57 68 65 6e 20 74 68 |Z.....*%|SWhen th|
|00006290| 65 20 50 72 69 6e 74 69 | 6e 67 20 4d 61 6e 61 67 |e Printi|ng Manag|
|000062a0| 65 72 20 77 61 73 20 69 | 6e 69 74 69 61 6c 6c 79 |er was i|nitially|
|000062b0| 20 64 65 73 69 67 6e 65 | 64 2c 20 67 72 65 61 74 | designe|d, great|
|000062c0| 20 63 61 72 65 20 77 61 | 73 20 74 61 6b 65 6e 20 | care wa|s taken |
|000062d0| 74 6f 20 6d 61 6b 65 20 | 74 68 65 20 00 00 06 00 |to make |the ....|
|000062e0| 01 00 00 00 a1 00 64 00 | 10 4f 4e 4c 4e 00 64 01 |......d.|.ONLN.d.|
|000062f0| 2c 01 10 01 e7 01 1c 02 | 1c 00 28 01 19 01 e7 0c |,.......|..(.....|
|00006300| 69 6e 74 65 72 66 61 63 | 65 20 74 6f 00 00 a1 00 |interfac|e to....|
|00006310| 64 00 10 4f 4e 4c 4e 00 | 64 01 39 01 1c 00 5a 01 |d..ONLN.|d.9...Z.|
|00006320| 28 01 d9 00 28 01 25 00 | 5a 53 74 68 65 20 70 72 |(...(.%.|ZSthe pr|
|00006330| 69 6e 74 65 72 20 64 72 | 69 76 65 72 73 20 61 73 |inter dr|ivers as|
|00006340| 20 67 65 6e 65 72 69 63 | 20 61 73 20 70 6f 73 73 | generic| as poss|
|00006350| 69 62 6c 65 20 69 6e 20 | 6f 72 64 65 72 20 74 6f |ible in |order to|
|00006360| 20 61 6c 6c 6f 77 20 61 | 70 70 6c 69 63 61 74 69 | allow a|pplicati|
|00006370| 6f 6e 73 20 74 6f 20 70 | 72 69 6e 74 20 00 06 00 |ons to p|rint ...|
|00006380| 02 00 00 00 a1 00 64 00 | 10 4f 4e 4c 4e 00 64 01 |......d.|.ONLN.d.|
|00006390| 8c 01 1c 01 d9 01 28 02 | 1c 00 28 01 25 01 d9 0d |......(.|..(.%...|
|000063a0| 77 69 74 68 6f 75 74 20 | 62 65 69 6e 67 00 06 00 |without |being...|
|000063b0| 01 00 00 00 a1 00 64 00 | 10 4f 4e 4c 4e 00 64 01 |......d.|.ONLN.d.|
|000063c0| 9a 01 28 00 5a 01 34 01 | 84 00 28 01 31 00 5a 3d |..(.Z.4.|..(.1.Z=|
|000063d0| 64 65 76 69 63 65 2d 73 | 70 65 63 69 66 69 63 2e |device-s|pecific.|
|000063e0| 20 54 68 65 72 65 20 61 | 72 65 20 74 69 6d 65 73 | There a|re times|
|000063f0| 2c 20 68 6f 77 65 76 65 | 72 2c 20 77 68 65 6e 20 |, howeve|r, when |
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.